M
mcarter
I have an excel spreadsheet and want to import data from ODBC oracle table.
I had to write the SQL code because the query could not be shown
graphically...
and it does work successfully. The problem is that I want to include
criteria in the WHERE clause for BRICKDATE, but cannot get it to work...
SELECT AC_WC_DEMOG_CRSTAB.BRICKDATE, AC_WC_DEMOG_CRSTAB.STATE,
Sum(AC_WC_DEMOG_CRSTAB."DEC1-3_RECORD_COUNT") AS "DEC1-3_RECORD_COUNT
FROM (AC_WC_DEMOG_CRSTAB)
WHERE (AC_WC_DEMOG_CRSTAB.STATE='NY')
GROUP BY AC_WC_DEMOG_CRSTAB.BRICKDATE, AC_WC_DEMOG_CRSTAB.STATE
I have tried this code but does not work...
WHERE (AC_WC_DEMOG_CRSTAB.STATE='NY') AND
(AC_WC_DEMOG_CRSTAB.BRICKDATE='2008-06-01 00:00:00'))
the date that is used is the actual date in the field that was copy/pasted in.
I need the SQL code that will work in MSQuery from exel to ODBC table.
Thanks
I had to write the SQL code because the query could not be shown
graphically...
and it does work successfully. The problem is that I want to include
criteria in the WHERE clause for BRICKDATE, but cannot get it to work...
SELECT AC_WC_DEMOG_CRSTAB.BRICKDATE, AC_WC_DEMOG_CRSTAB.STATE,
Sum(AC_WC_DEMOG_CRSTAB."DEC1-3_RECORD_COUNT") AS "DEC1-3_RECORD_COUNT
FROM (AC_WC_DEMOG_CRSTAB)
WHERE (AC_WC_DEMOG_CRSTAB.STATE='NY')
GROUP BY AC_WC_DEMOG_CRSTAB.BRICKDATE, AC_WC_DEMOG_CRSTAB.STATE
I have tried this code but does not work...
WHERE (AC_WC_DEMOG_CRSTAB.STATE='NY') AND
(AC_WC_DEMOG_CRSTAB.BRICKDATE='2008-06-01 00:00:00'))
the date that is used is the actual date in the field that was copy/pasted in.
I need the SQL code that will work in MSQuery from exel to ODBC table.
Thanks