Search Results get_defined_balance




Overview

PAY_CA_GROUP_LEVEL_BAL_PKG is an Oracle EBS Payroll (PAY) package owned by the APPS schema and classified under the OTHER API category. It provides Canadian group-level balance calculation logic, allowing callers to retrieve the value of a defined payroll balance aggregated across a set of payroll dimensions. Rather than returning a balance for a single assignment, the group-level routines accept context parameters such as GRE, jurisdiction, organization, location, payroll, and pay basis type, so that a balance can be evaluated for a population of assignments that share a common grouping.

The package is declared with AUTHID CURRENT_USER and a header dated 2007, reflecting its long-standing role in Canadian payroll balance processing. It exposes a small, focused interface of three documented functions, making it suitable for reuse by other payroll packages, forms, and reporting logic. The presence of the GET_DEFINED_BALANCE entry point, which the user searched for, indicates the package also supports resolving a defined balance by name and dimension, typically as a precursor to the group-level calculation.

Key Procedures and Functions

  • CA_GROUP_LEVEL_BALANCE — The primary calculation function. It returns a numeric balance value for a named balance within a specified time dimension and effective date, using optional grouping parameters (source, GRE, jurisdiction, organization, location, payroll, and pay basis type) to scope the population. This is the routine custom code should call when it needs a Canadian group-level balance result.
  • GET_DEFINED_BALANCE — Resolves and returns the balance value for a given balance name and dimension, with an optional business group identifier. It carries a PRAGMA RESTRICT_REFERENCES(..., WNDS) declaration, confirming it does not write database state, which makes it safe for use inside SQL and query contexts.
  • CA_GROUP_LEVEL_BALANCE_RB — A run-balance-oriented variant of the group-level calculation, accepting the same grouping parameters plus a flag. It is intended for scenarios that require run balance semantics rather than latest-balance semantics.

Tables Accessed

The package reads from a broad set of payroll and HR tables, consistent with resolving balance definitions and aggregating assignment-level data:

Usage Notes

This package is typically invoked from Canadian payroll processing logic where a balance must be evaluated across a group rather than for an individual assignment — for example, in statutory calculation, reporting, or validation routines. It is documented as referenced by four other packages, indicating it functions as a shared utility rather than a standalone entry point.

Because GET_DEFINED_BALANCE is declared with PRAGMA RESTRICT_REFERENCES (WNDS), it may be called from SQL statements safely. Callers should supply the effective date and grouping parameters explicitly where the balance definition is context-sensitive, and should be aware that omitting optional parameters narrows the group scope. As with all APPS-owned APIs, custom code should call the package through public synonyms and avoid direct dependency on the underlying tables. Functionality specific to Canada requires the appropriate legislation and payroll configuration to be present for meaningful results.