Search Results per_bil_shd




Overview

PER_BIL_SHD is a shadow (suffix "_SHD") server-side PL/SQL package owned by the APPS schema and defined with AUTHID CURRENT_USER, indicating that its SQL statements execute under the privileges of the calling user rather than the package owner. The "BIL" component of the name associates it with the billing and assignment side of Oracle Human Resources (PER), specifically the date-tracked business group information that underlies HR billing and assignment records. In the Oracle EBS 12.1.1 and 12.2.2 architectures, shadow packages such as this one expose the internal record structure and shared validation utilities used by the corresponding entity API and its table handlers.

The package declares a global record type, g_rec_type, whose fields (type, business_group_id, object_version_number, id_value, three foreign-key values, seven text values, three numeric values, three date values, and created_by) mirror the generic, extensible column layout used by the HR summary/billing data model. A global variable g_old_rec stores the prior image of a row, and g_api_dml records whether a DML operation is executing from within the API. The header is dated 2003 with a version of 115.7, consistent with a long-lived, largely static piece of the PER schema.

Key Procedures and Functions

  • RETURN_API_DML_STATUS — Returns the current value of the private global g_api_dml boolean, indicating whether an INSERT, UPDATE, or DELETE is being issued from within the entity API at the time of execution. It exists to support database triggers and dependent logic that must distinguish API-driven DML from direct DML.
  • CONSTRAINT_ERROR, API_UPDATING, LCK — Internal row-processing and concurrency helpers. CONSTRAINT_ERROR handles constraint-related failures during API processing, API_UPDATING tracks the update path, and LCK performs row locking against the target record.
  • CONVERT_ARGS — Normalizes or translates argument values passed into the API routines into the formats expected by the entity's internal logic.
  • ROW_EXIST, LOOKUP_EXISTS, SEQUENCE_EXIST — Existence checks verifying that a target row, a referenced lookup value, and the relevant sequence definition are present before processing continues.
  • CHECK_RESTRICTION_SQL, VALID_VALUE, GET_RESTRICTION_MEANING — Validation routines that enforce value restrictions defined for the entity, confirm that a supplied value is valid, and resolve the descriptive meaning of a restriction for error reporting.
  • PARENT_FOUND, CHK_DATE_VALID — Verify that the required parent (typically the business group or parent record) is present and that date values conform to the entity's date-tracked validity rules.

Tables Accessed

The package references three documented tables through APPS synonyms. ALL_CONSTRAINTS is queried for constraint metadata used by CONSTRAINT_ERROR and the restriction-checking routines. HR_SUMMARY supplies the summarized HR/billing data against which row existence, parent validation, and value checks are performed. DUAL is used for scalar evaluations and single-row lookups. No direct DML against base entity tables is documented in this excerpt; the package predominantly supports validation, locking, and status reporting for its owning API.

Usage Notes

PER_BIL_SHD is not intended for direct invocation by end users. It is called by five other packages, which are the entity APIs and table handlers that perform insert, update, and delete operations against the underlying HR billing records. Database triggers on the affected tables use RETURN_API_DML_STATUS to determine whether a change originated from the supported API path. The package also supports concurrent programs and Oracle Forms-based maintenance screens that invoke the parent API. Custom code should call the primary entity API rather than this shadow package, since the "_SHD" routines expose internal implementation details, global state (g_old_rec, g_api_dml), and validation helpers that are not part of the public, supported interface.