cancel
Showing results for 
Search instead for 
Did you mean: 

HANA Procedure Dynamic Where Condition

eminebaydar1
Explorer
0 Kudos

Hi All,

I tried to create procedure in Hana Studio. I could create string variable for where condition syntax. But I couldn't use it in select syntax.

Its giving the error ; "Could not execute 'ALTER PROCEDURE ZPROC_SEARCH_WERKS (in II_SALESID INTEGER, out OS_OUTPUTSTRG VARCHAR(200) ) ...'SAP DBTech JDBC: [257]: sql syntax error: incorrect syntax near ";": line 44 col 19 (at pos 1192)"

I like to have your valuable suggestion and advice for this issue.

Thanks in Advance,

Emine Baydar

former_member27
Community Manager
Community Manager
0 Kudos

Hi Emine,

Please note i changed the tags as per this moderation alert: "This question is specific HANA DB procedure and not related to ABAP development on CE"

Regards,

Dedi

Accepted Solutions (0)

Answers (1)

Answers (1)

venkateswaran_k
Active Contributor
0 Kudos

Hi

Can you change the sql portion as below

lv_where = 'MATNR IN (' || VS_OUTPUTSTRG1 || ')'
SQLMARD = SELECT * FROM MARD WHERE (:LV_WHERE)