|
Archives of the TeradataForumMessage Posted: Sat, 23 Nov 2002 @ 01:44:36 GMT
Syed, I recently ran into this issue, and here's what I found. CALL DBC.SysExecSQL('SELECT COUNT(*) INTO :rowcount from :TableNames'); Your entire DML statement is being treated as a string, because of the ''. You need to seperate your variables out, like this: CALL DBC.SysExecSQL( 'SELECT Count(*) AS CNT INTO ' || :rowcount || 'FROM || :TableNames || ';' ); Note 2 additions to your original. You need to Name all expressions in Select Into statements. Also, I've found (V2R4.13) that a DynamicSQL statement needs to include a ';'. Hope this helps, Sam
| ||||||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||||||
Copyright 2016 - All Rights Reserved | ||||||||||||||||||||||||||||||||||||||||||||||||
Last Modified: 15 Jun 2023 | ||||||||||||||||||||||||||||||||||||||||||||||||