4.5.4 Using Data Values in Named Program Units
In named program units like functions and procedures, to make code more reusable, you can accept values the business logic depends on as input parameters. Then pages invoking the function or procedure can pass in appropriate values by referencing page items.
In cases where that's not a priority, use the GET_TYPE()
routines in the APEX_SESSION_STATE package to access the value of page
items, application items, or built-in substitution string names. To work with data
values as strings in your function and procedure code, the V() function
is identical to apex_session_state.get_varchar2() and fewer characters
to type.
Parent topic: Using Data Values in SQL and PL/SQL