Skip to Main Content

APEX

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!

Retrieve values from a page item type select list

David DAMIANOSJan 22 2024

Hello,

Here is my problem :

I have 1 page of type form that contains two page items of type select list (LIST_PERFORMANCETYPE and LIST_FINALOUTLOOK). Those lists have the same parameters. Lets take LIST_PERFORMANCETYPE for exemple. Everything is set on default and for the “List of Values” field, I have set “type” → SQL Query and the sql query is “select PERFORMANCETYPESC as d, PERFORMANCETYPESC as r from GPN_PERFORMANCETYPE”.

So long everything is working as expected. The list displays the right values from the right table. Now I have a button called Next which has a dynamic action. This Action is executed when click on the button and the on the true settings, action is “Execute Server-side Code”, Language : “PL/SQL” and the query is

Begin
INSERT INTO GPN_GPN
(
GPN,
PERFORMANCETYPESC,
FINALOUTLOOKSC,
)
VALUES
(
'DP4',
nvl(:LIST_PERFORMANCETYPE, 'test1'),
nvl(:LIST_FINALOUTLOOK, 'test2')
);
commit;
End;

So when I select the values for the two lists, I check my table GPN_GPN and for the columns PERFORMANCETYPESC and FINALOUTLOOKSC, ‘test1’ and ‘test2’ are inserted which means that :LIST_PERFORMANCETYPE and :LIST_FINALOUTLOOK are being recognized as NULL value.

Can you help me on how I can manipulate the values selected from my two lists ?

Best Regards,
David

This post has been answered by InoL on Jan 22 2024
Jump to Answer
Comments
Post Details
Added on Jan 22 2024
3 comments
792 views