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!

Using a select list in an interactive report

hpd305Mar 19 2021

I'm currently building an application in APEX 5.1. I have an interactive report with a select list created in a query as described in the Oracle documentation

SELECT  empno "Employee #", 
    ename "Name",
    APEX_ITEM.SELECT_LIST(
        p_idx           =>   3,
        p_value         =>   deptno,
        p_list_values   =>   'ACCOUNTING;10,RESEARCH;20,SALES;30,OPERATIONS;40' DEPARTMENT,
    'Submit' as SUBMIT_DEPT
  FROM  emp;

The 'Submit' column is intended to be a button with an associated jQuery selector that calls a dynamic action on click to write to a table that stores the employee number and the corresponding department selection.
So if a user selects 'OPERATIONS' from the select list on a row that corresponds to employee # '100' then clicks the 'Submit' button, a dynamic action would write to a table called 'SELECTED_DEPARTMENTS'
insert into SELECTED_DEPARTMENTS (EMPNO, DEPARTNO) values ('100', '40')
I have used loops to read select lists or check boxes on entire reports when a page is submitted but, in this case, I want to only submit the values a single row in the report.
Thanks!

Comments
Post Details
Added on Mar 19 2021
3 comments
2,491 views