Marcelo Velasquez
May 18th, 2000, 08:50 AM
Hi
I am using a query that comes back several data, but I need to validate some data with other table, that verifies if certain schedule and it dates they are in this table. See the example
SELECT HR_INI,HR_FIM, FIELD03,FIELD04...ETC. FROM TABLE1,TABLE 2, TABLE3
WHERE <CONDITIONS> AND NOT EXISTS (SELECT FIELDXX FROM TABLEXX
WHERE TABLEXX.FIELDYY = TABLE1.FIELDYY AND TABLEXX.FIELD_DATE = ' 2000-05-22 15:30 ')
In the example I want above to compare the field TABLEXX.FIELD_DATE with the concatenation certain date (20000-05-22) with the hour HR_INI, tried to use FORMAT, but I didn't get, I tried the following (the last line):
SQL = SQL & " WHERE TABLEXX.FIELDYY = TABLE1.FIELDYY AND "
SQL = SQL & " TABLEXX.FIELD_DATE = '" & FORMAT ("
then I don't know how I connect the date and HR_INI
If somebody can help me I thank
I am using a query that comes back several data, but I need to validate some data with other table, that verifies if certain schedule and it dates they are in this table. See the example
SELECT HR_INI,HR_FIM, FIELD03,FIELD04...ETC. FROM TABLE1,TABLE 2, TABLE3
WHERE <CONDITIONS> AND NOT EXISTS (SELECT FIELDXX FROM TABLEXX
WHERE TABLEXX.FIELDYY = TABLE1.FIELDYY AND TABLEXX.FIELD_DATE = ' 2000-05-22 15:30 ')
In the example I want above to compare the field TABLEXX.FIELD_DATE with the concatenation certain date (20000-05-22) with the hour HR_INI, tried to use FORMAT, but I didn't get, I tried the following (the last line):
SQL = SQL & " WHERE TABLEXX.FIELDYY = TABLE1.FIELDYY AND "
SQL = SQL & " TABLEXX.FIELD_DATE = '" & FORMAT ("
then I don't know how I connect the date and HR_INI
If somebody can help me I thank