1. Overview
This blog talks about the setting Page/Application Item value within PLSQL Package/Procedure/Function.
2. Technologies and Tools Used
The following technologies have been used to achieve this functionality,
- PLSQL
- APEX API
3. Use Case
To set the session state page item or application item value within PLSQL.
4. Architecture
Usually, if we want to set a value for the page item or application item, our regular practice will be setting a value using a bind variable(syntax => :PX_PAGE_ITEM) in the APEX page-level plsql processes.
e.g.
BEGIN
:PX_PAGE_ITEM := ‘Hello’;
END;
Suppose, if there is a scenario to set a value for page/application item within plsql package/procedure/function and also it should be held in session state of the target page, then we can follow the below method,
Begin
APEX_UTIL.set_session_state( p_name => ‘PX_PAGE_ITEM’
, p_value => ‘Hello’);
End;