YEAR is an ODBC function which doesn't exist in StandardSQL/Teradata, but the ODBC driver replaces it with correct syntax.
This is always causing confusion, because it's ony working in SQLA and only for DML statements, when you try to put in in a view it will fail. In the ODBC manual you'll find a list of those ODBC functions, e.g. LENGTH, LTRIM, MONTH, etc.
This odd behaviour can be switched off in the ODBC options, just check the "Disable Parsing".
The DATE '2012-03-26' is the only syntax which is supposed to work in any place anytime, you should check if it's actually failing. Is there an error message or what?
Dieter
YEAR is an ODBC function which doesn't exist in StandardSQL/Teradata, but the ODBC driver replaces it with correct syntax.
This is always causing confusion, because it's ony working in SQLA and only for DML statements, when you try to put in in a view it will fail. In the ODBC manual you'll find a list of those ODBC functions, e.g. LENGTH, LTRIM, MONTH, etc.
This odd behaviour can be switched off in the ODBC options, just check the "Disable Parsing".
The DATE '2012-03-26' is the only syntax which is supposed to work in any place anytime, you should check if it's actually failing. Is there an error message or what?
Dieter