‎2010 Sep 30 8:23 PM
Hi Experts,
I want to dynamically pass the field in Update statement in Native SQL. For eg.
data: str1 type string.
str1 = 'MARKETS'.
EXEC SQL.
UPDATE PRDT.TBVEHDS4 SET (str1) = :'U'
WHERE VEH_NO = :'K1WK-54520'
AND SEGMENT_NO = :'01'
ENDEXEC.
But this is not taking (str1) as MARKETS field to update as U , its taking STR1 itself, Giving native SQL exception as Invalid Token as we are using DB2 as external DB system.
I checked with field-symbols also, but nothing helped.
Please help, thanks in Advance.
Regards,
Abhishek
‎2010 Sep 30 8:39 PM
Hi,
Check this demo program in SE38 ADBC_DEMO, take as example to construct your own dynamic native sql
Regards,
Felipe