In my previous blog , I have shared the way to query APEX_COLLECTIONS data from database backend itself. That approach needs to follow three steps.
- Setting up Workspace
- Setup Application ID
- Setup Session id
Today let’s explore the APEX_SESSION API. And specifically ATTACH procedure. Which is helpful to achieve the same.
This procedure based on the given application and session current, sets environment and runs the Initialization PL/SQL Code.
BEGIN apex_session.attach (p_app_id => 177, -- Application ID p_page_id => 5, -- Page ID p_session_id => 19278163964528 -- Session ID ); END;
After executing the ATTACH procedure we can query the APEX collections from back end and also we can Access the Page ITEM Values
This procedure detaches from the current session, resets the environment and runs the application’s Cleanup PL/SQL Code. This procedure does nothing if no session is attached.
Other Useful Links