TEradata dynamic sql output
TEradata dynamic sql output
(OP)
Hi Guys,
I have TERADATA STORED procedure that have dynamic sql inside.
I would like to check the output the dynamic sql compiled and got struggle with the syntax even after i did the google.
Your help would be appreciated.
Thanks,
I have TERADATA STORED procedure that have dynamic sql inside.
I would like to check the output the dynamic sql compiled and got struggle with the syntax even after i did the google.
CODE
SET v_SQL = 'SELECT TOP 10* from table name where id = ' || v_number || ';'; -- I would like to check the output of v_sql before I execute CALL DBC.SysExecSQL(:v_SQL);
Your help would be appreciated.
Thanks,
RE: TEradata dynamic sql output
SELECT TOP 10* from table name where id = ##
Replace ## with a suitable ID Number, assuming variable v_Number is a number.
Ian