Archives of the TeradataForum
Message Posted: Sat, 31 May 2003 @ 09:36:23 GMT
Subj: | | Re: BTEQ and RTRIM |
|
From: | | Dieter N�th |
Paul Swier wrote:
| I have been trying to run a query in BTEQ using rtrim and I have not been succesful. Is it not possible? Below is a sample query.
The mesage I receive is: *** Failure 3706 Syntax error: expected something between '(' and the word 'CHILDDB'. | |
| select DISTINCT 'ALTER TABLE '||RTRIM(CHILDDB)||'.'|| CHILDTABLE ||' DROP CONSTRAINT '||INDEXNAME||'; ' from DBC.All_RI_Children
where childdb<>PARENTDB | |
RTRIM is ODBC SQL, it only works in QueryMan when you enable Option -> Query -> "Allow use of ODBC SQL Extensions in queries" and
the ODBC driver replaces it with an Teradata SQL equivalent funtion (TRIM).
Please check the ODBC User Guide manual, table 4-16 for supported ODBC functions.
But i wouldn'd recommend using it, because the query won't run in a different environment.
Dieter
|