Results for “availability_value”

8 results




AI-generated from documented ETRM metadata — verify critical details on the linked pages.

Overview

HR_CALENDAR_PKG is a PL/SQL package body owned by the APPS schema that provides the core programmatic logic for Oracle EBS calendar management. Its central purpose is the construction, denormalisation and querying of calendars and their associated availability patterns. In Oracle Human Resources and Oracle Payroll, a calendar is a higher-level construct that aggregates one or more work patterns (defined in the HR_PATTERN_* tables) and assigns them to specific units, thereby producing a day-by-day availability picture for workers, organizations or business units.

Rather than requiring every consumer to re-derive availability by traversing the underlying pattern definitions at runtime, HR_CALENDAR_PKG flattens, or "denormalises," the pattern data into the HR_CALENDAR_USAGES and HR_EXCEPTION_USAGES structures. This pre-computed representation is what downstream processes — absence accruals, payroll period processing, workforce scheduling and self-service calendar displays — read when they need to know whether a given date is a working day, a non-working day or an exception day for a given calendar.

Key Procedures and Functions

The ETRM metadata records eleven documented program units in this package. Their responsibilities map to three broad categories:

  • DENORMALISE_CALENDAR — The generative routine. It expands the pattern and exception definitions linked to a calendar into the denormalised usage rows, forming the persistent availability picture that all other routines and external callers rely on.
  • START_DATE and END_DATE — Date boundary utilities that establish the effective range over which calendar or pattern data applies.
  • AVAILABILITY and TOTAL_AVAILABILITY — The primary query interfaces, returning the availability state of a calendar on a given date and the aggregate availability across a range respectively.
  • AVAILABILITY_VALUE and SCHEDULE_LEVEL_VALUE — Value-level helpers that resolve the numeric or coded representation of availability and of schedule levels, typically used to drive display and comparison logic in calling forms.
  • SCHEDULE_ROWCOUNT — A counting routine that returns the number of schedule rows associated with a calendar, often used for sizing collections or validating that a calendar has been populated.
  • PURPOSE_USAGE_ID — An identifier resolver that returns the usage identifier for a given calendar usage purpose, linking calendar definitions to their HR_PATTERN_PURPOSE_USAGES context.

Tables Accessed

The package operates directly against the following base tables through APPS synonyms:

  • HR_CALENDARS — The master calendar definition (name, type and associated attributes).
  • HR_CALENDAR_USAGES — The denormalised per-date availability rows produced by the package and consumed by callers.
  • HR_EXCEPTION_USAGES — Exception days overriding the standard pattern within a calendar.
  • HR_PATTERN_BITS, HR_PATTERN_CONSTRUCTIONS, HR_PATTERN_EXCEPTIONS, HR_PATTERN_PURPOSE_USAGES — The underlying work-pattern model from which calendar availability is derived.

In addition, the dependency listing shows a reference to HR_UTILITY (an HRMS helper package) and the SYS STANDARD package. The package references HR_CALENDAR_PKG (its own specification) and is documented as being referenced by three other database objects.

Usage Notes

HR_CALENDAR_PKG is almost never invoked directly by end users. It is called from HRMS forms such as the Calendar and Work Pattern windows, from concurrent programs that regenerate calendar data, and from custom PL/SQL that must determine working-day availability. Typical invocations follow a two-step pattern: DENORMALISE_CALENDAR is executed when calendar or pattern definitions change, and AVAILABILITY or TOTAL_AVAILABILITY is then called during transactional processing. Because the package is documented as not referenced by any database object outside the three dependent packages, custom code should call only the documented API surface and avoid direct DML against HR_CALENDAR_USAGES.