Search Results get_view_mode
Overview
PAY_CA_BALANCE_VIEW_PKG is an Oracle Payroll package that supports the Canadian localization of payroll balance reporting. It provides the server-side logic required to locate, cache, and return assignment-level balance values for Canadian balance codes within Oracle EBS 12.1.1 and 12.2.2. The package was originally created in March 1999 and evolved through several revisions, most notably the migration of shared code from the United States tax balance package (PAY_US_BALANCE_VIEW_PKG) into a common core implementation. In the 115.5 revision, dated 17 February 2004, Oracle removed several routing and navigation subprograms (goto_per_latest_balances, goto_asg_latest_balances, goto_route, and run_route) as part of Bug 3331035, reflecting a simplification of the package's responsibilities toward data retrieval and view-mode management.
The package is defined with AUTHID CURRENT_USER, and its header defines a LatBal record type that mirrors the structure of PAY_ASSIGNMENT_LATEST_BALANCES, including the latest balance identifier, assignment action, value, action sequence, effective date, and the expired balance equivalents. This record type underpins the package's balance presentation logic.
Key Procedures and Functions
The documented API surface comprises 44 procedures and functions, which fall into three functional groups.
- View-mode control: GET_VIEW_MODE and SET_VIEW_MODE. These are the entry points associated with the search term "set_view_mode." They allow a caller to establish and interrogate the current presentation or routing mode used to determine which balance data is displayed. Forms and custom screens invoke SET_VIEW_MODE before querying balances and GET_VIEW_MODE to confirm the active mode.
- Session variable management: SET_SESSION_VAR, GET_SESSION_VAR (two overloaded versions), and CLEAR_SESSION_VARS. Introduced in February 2000, these subprograms maintain package-level state across calls within a database session, avoiding repeated lookups of context information.
- Debugging utilities: DEBUG_INIT, DEBUG_WRAP, DEBUG_SET_MAX, DEBUG_ON, DEBUG_OFF, DEBUG_RESET, DEBUG_DUMP, DEBUG_DUMP_TO_TRACE, DEBUG_DUMP_ERR, DEBUG_DUMP_LIKE, DEBUG_GET_LINE, DEBUG_GET_COUNT, DEBUG_MSG, DEBUG_ERR, and DEBUG_TOGGLE. These provide a standardized tracing and diagnostics framework used during development and support investigation.
Additional procedures in the full 44-member list handle balance caching and retrieval; the historical clear_asgbal_cache routine is part of this caching mechanism.
Tables Accessed
The package reads and writes against the core Payroll balance model through APPS synonyms. PAY_ASSIGNMENT_LATEST_BALANCES and PAY_ASSIGNMENT_ACTIONS supply the latest and expired balance values and their action sequencing. PAY_BALANCE_TYPES, PAY_BALANCE_DIMENSIONS, PAY_BALANCE_CONTEXT_VALUES, PAY_DEFINED_BALANCES, and FF_CONTEXTS define the balance codes, their dimensional structure, and context values that drive balance selection, including Canadian-specific balance codes. PAY_PAYROLL_ACTIONS and PER_TIME_PERIODS provide payroll run and period context for effective-dating. HR_ALL_ORGANIZATION_UNITS and HR_ORGANIZATION_INFORMATION support organization-level balance segregation. DUAL is used for singleton lookups, and PLITBLM is the PL/SQL table used in bulk operations.
Usage Notes
PAY_CA_BALANCE_VIEW_PKG is referenced by 18 other packages, making it a shared dependency rather than an end-user entry point. It is typically invoked from Canadian payroll balance inquiry forms and related concurrent processes, and from custom PL/SQL that requires assignment-level balance values. Custom code should call SET_VIEW_MODE before retrieving balances and may use SET_SESSION_VAR and GET_SESSION_VAR to preserve context. Direct DML against the underlying tables should be avoided; the package encapsulates the supported access path. Debug procedures are intended for controlled diagnostic use and should not be enabled in production sessions.
-
PACKAGE: APPS.PAY_CA_BALANCE_VIEW_PKG
12.1.1
-
PACKAGE: APPS.PAY_CA_BALANCE_VIEW_PKG
12.2.2
-
PACKAGE: APPS.PAY_US_BALANCE_VIEW_PKG
12.1.1
-
PACKAGE: APPS.PAY_US_BALANCE_VIEW_PKG
12.2.2
-
PACKAGE BODY: APPS.PAY_CA_BALANCE_VIEW_PKG
12.2.2
-
PACKAGE BODY: APPS.PAY_US_BALANCE_VIEW_PKG
12.1.1
-
PACKAGE BODY: APPS.PAY_CA_BALANCE_VIEW_PKG
12.1.1
-
PACKAGE BODY: APPS.PAY_US_BALANCE_VIEW_PKG
12.2.2