I am trying to "translate" the following command into dynamic SQL to be used in a procedure:
SELECT *, 'IDS' AS SYSID FROM MODE_TEST.USR02
Can someone help with this question? I am facing problems with the 'IDS'.
thanks,
regards,
You can use like below:
do begin declare str nvarchar(1000); str='SELECT *,''IDS'' AS "SIYSID" FROM MODE_TEST.USR02'; execute immediate :str; end;
You can use like below: