This post was inspired by a question on the OTN APEX forum, which contains requests for two fairly common scenarios:
1) A select list dependent on another select list
2) A report the updates based on the selections.
The original post submitted the page after each select change - APEX 4.x makes this unnecessaary thanks to cascading select lists.
And the report can also be refreshed without submitting the page thanks to Dynamic Actions.
So a solution can be formed declaratively without submitting the page, we just need logical SQL to go with it.
The final result doesn't have many components, and the demo is available here in my sample application.
The P25_DEPT LOV definition is simply
The P25_EMP item has a 'Cascading LOV Parent Item' of "P25_DEPT", and LOV which ensures employees are shown even with no dept selected.
I've enabled display of null values in both select lists.
My report SQL is
The dynamic action fires on Change of P25_EMP, and refreshes the report region.
Simple, effective use of declarative APEX features - so you can spend more time on stuff like jQuery ;-)
1) A select list dependent on another select list
2) A report the updates based on the selections.
The original post submitted the page after each select change - APEX 4.x makes this unnecessaary thanks to cascading select lists.
And the report can also be refreshed without submitting the page thanks to Dynamic Actions.
So a solution can be formed declaratively without submitting the page, we just need logical SQL to go with it.
The final result doesn't have many components, and the demo is available here in my sample application.
![]() |
Page rendering properties |
select dname, deptno from dept
The P25_EMP item has a 'Cascading LOV Parent Item' of "P25_DEPT", and LOV which ensures employees are shown even with no dept selected.
select ename, empno from emp where deptno = :P25_DEPT or :P25_DEPT is null
I've enabled display of null values in both select lists.
My report SQL is
select empno, ename, jobwith 'Page Items to Submit' as "P25_EMP", and I've ensured 'Enable Partial Page Refresh' report attribute is Yes.
from emp
where job = (select job from emp where empno = :P25_EMP)
or :P25_EMP is null
The dynamic action fires on Change of P25_EMP, and refreshes the report region.
Simple, effective use of declarative APEX features - so you can spend more time on stuff like jQuery ;-)