Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How can we pass multiple values to the parameter inside Decode statement

Uday PJun 1 2022 — edited Jun 1 2022

Hi,
Can any one explain how below statement is executing.
Select * from table A
where
INVOICE_ID IN (DECODE(:P_INVOICE_ID,NULL,INVOICE_ID,:P_INVOICE_ID))
if i try to pass multiple values to :P_INVOICE_ID, its not working as expected.
i,e,. it is not considering the all parameter values.
Please see the attachment.

Screenshot.png
Many thanks

Comments
Post Details
Added on Jun 1 2022
4 comments
1,402 views