Quantcast
Channel: SCN : All Content - All Communities
Viewing all articles
Browse latest Browse all 3523

syntax error for dynamic column for update query

$
0
0

Hi Experts,

 

Please check following query. i have incorporated it in my store procedure.

 

EXEC 'update TBL_M set '||:COL_NAME||' = '||:R."W_QTY"||'where WID ='||:R."W1";

 

i am getting following error.

 

Could not execute 'call USP_CW' in 131 ms 107 µs .

SAP DBTech JDBC: [257]: sql syntax error:--: line 29 col 5 (at pos 625): [257] (range 3) sql syntax error exception: sql syntax error: incorrect syntax near "W1": line 1 col 44 (at pos 44)

 

could you please let me know, where i am doing wrong.


Viewing all articles
Browse latest Browse all 3523

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>