Search Results get_worksheet_id
Overview
PSB_POSITIONS_PVT is a private (PVT) PL/SQL API package in the Oracle EBS Public Sector Budgeting (PSB) module, owned by APPS. It provides the core server-side processing logic for position worksheets, which are the working constructs used to define, validate, and budget positions during an award or budget cycle. The package is not exposed as a public API; instead, it is invoked internally by forms, concurrent programs, and other PSB packages (it is referenced by 23 other packages). Its primary responsibilities include managing the worksheet-level context (identifying the active worksheet, its date range, and selection criteria), performing CRUD operations against the PSB position and budget tables, validating salary and assignment data, and creating default assignments for budget positions.
The "get_worksheet_flag" search term maps directly to the public function Get_Worksheet_Flag, which returns the current worksheet flag stored in the package global g_worksheet_flag (default 'N'). This flag, along with the worksheet ID, start date, end date, and select date globals, controls which worksheet is active for subsequent position operations.
Key Procedures and Functions
The package exposes the following documented procedures and functions, grouped by function:
- Initialize_View — Sets the package-global worksheet context (worksheet ID, start date, end date, and select date) so that subsequent operations act on the correct worksheet.
- Define_Worksheet_Values — Defines a worksheet for a given position and budget source, returning the resulting worksheet ID, start date, and end date. This is the primary entry point for establishing worksheet parameters.
- Get_Start_Date, Get_End_Date, Get_Select_Date, Get_Worksheet_Flag, Get_Worksheet_ID — Accessor functions that return the corresponding package-global values. All are declared with RESTRICT_REFERENCES (WNDS, WNPS), meaning they do not write database state or package state and can be safely called from SQL and PL/SQL.
- Insert_Row, Update_Row, Delete_Row, Lock_Row, Add_Row — Standard table handlers for creating, modifying, deleting, and locking position worksheet rows.
- Delete_Assignments, Delete_Assignment_Employees — Remove assignment records and their associated employee links for a position.
- Modify_Assignment — Updates an existing assignment record for a position.
- Validate_Salary — Performs salary validation logic for a position.
- Position_Ws_Validation — Validates the position worksheet as a whole, ensuring data integrity before submission.
- Create_Default_Assignments — Generates default assignment records for a budget position.
- Rev_Check_Allowed — Checks whether revision processing is allowed for the current worksheet context.
- Get_Debug — Returns debug information, useful for troubleshooting.
Tables Accessed
The package reads and writes the following documented tables (via APPS synonyms): POSITION and BUDGET_POSITIONS (PSB_BUDGET_POSITIONS) and BUDGET_REVISIONS store the core position and budget data; PSB_ATTRIBUTES, PSB_ATTRIBUTE_VALUES, PSB_BUDGET_GROUPS, PSB_BUDGET_PERIODS, PSB_BUDGET_YEAR_TYPES, and PSB_DEFAULTS hold configuration and attribute data used during validation and worksheet setup; PSB_DEFAULT_ACCOUNT_DISTRS and PSB_DEFAULT_ASSIGNMENTS store distribution and assignment records created by CREATE_DEFAULT_ASSIGNMENTS and MODIFY_ASSIGNMENT; PSB_ELEMENT_POS_SET_GROUPS and PSB_ENTITY_ASSIGNMENT link elements, positions, and entities; PSB_EMPLOYEES provides employee data for assignment processing; GL_CODE_COMBINATIONS supplies accounting flexfield values used in distribution validation; and FND_ID_FLEX_SEGMENTS provides key flexfield segment definitions used to interpret GL accounts referenced by PSB defaults and distributions.
Usage Notes
PSB_POSITIONS_PVT is an internal package. It is typically invoked from the Public Sector Budgeting position entry forms, from PSB concurrent programs that process budget worksheets, and from other PSB packages that need to manipulate position worksheets or validate position data. Custom code should not call this package directly; instead, use the public PSB APIs or the standard forms. Where custom integration is unavoidable, callers must first invoke Initialize_View or Define_Worksheet_Values to establish the worksheet globals, then invoke the relevant handler. Because the package uses package-global state, calls are not re-entrant and the worksheet context must not be changed mid-transaction. The accessor functions (including Get_Worksheet_Flag) may be safely called from SQL. Developers troubleshooting worksheet behavior should use Get_Debug to inspect internal state.
-
PACKAGE: APPS.PSB_POSITIONS_PVT
12.1.1
-
PACKAGE BODY: APPS.CN_PAYMENT_WORKSHEET_PVT
12.1.1
-
PACKAGE BODY: APPS.CN_PAYMENT_WORKSHEET_PVT
12.2.2
-
APPS.CN_PAYMENT_WORKSHEET_PVT dependencies on CN_PAYMENT_WORKSHEETS
12.1.1
-
APPS.CN_PAYMENT_WORKSHEET_PVT dependencies on CN_PAYMENT_WORKSHEETS
12.2.2
-
APPS.CN_PAYMENT_WORKSHEET_PVT dependencies on CN_REPOSITORIES
12.2.2
-
APPS.CN_PAYMENT_WORKSHEET_PVT dependencies on CN_REPOSITORIES
12.1.1
-
PACKAGE BODY: APPS.PSB_POSITIONS_PVT
12.1.1
-
APPS.CN_PAYMENT_WORKSHEET_PVT dependencies on FND_API
12.1.1
-
APPS.CN_PAYMENT_WORKSHEET_PVT dependencies on FND_API
12.2.2