Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Decode function in SAP BODS

Hi Gurus,

Could u help me with the below decode statement i used in where clause?

Query.CALMONTH = $GV_Calmonth

decode(Query.CALMONTH  is null,Query.CALMONTH=('0'||substr(add_months( sysdate( ),-1) ,6,2)||'.'||substr(sysdate(),1,4)),Query.CALMONTH)

Error:

Invalid WHERE clause. Additional information: <Syntax error at line <7>: <decode(Query.CALMONTH  is null,Query.CALMONTH=('0'||substr(add_months( sysdate( ),-1) ,6,2)||'.'||substr(sysdate(),1,4)),Query.CA>: near <decode> found <identifier>>.

1 error(s), 0 warning(s).

Check and fix the syntax and retry the operation. (BODI-1112394)>. (BODI-1111078)

Not what you were looking for? View more on this topic or Ask a question