Search Results hri_time_bimonth_v




Overview

HRI_BPL_TIME is a business-layer PL/SQL package body owned by the APPS schema in Oracle E-Business Suite. It belongs to the HRI (Human Resources Intelligence) family of database objects and provides low-level date arithmetic utilities used by Oracle HRMS reporting, analytics, and time-based calculations. Its principal responsibility is to resolve a given date to the boundaries of the period that contains it, where the period granularity may be one of several calendar types: year, semiyear, quarter year, bimonth, or month. This functionality supports applications that must aggregate, filter, or bucket HR data by standard enterprise periods rather than by arbitrary date ranges.

Key Procedures and Functions

The package exposes two documented functions. Both accept a date and a period identifier and return a DATE result.

  • GET_PERIOD_START_DATE — For a supplied start date and period type (p_start_date and p_period), returns the start date of the period in which that date lies. If either argument is NULL the function raises NO_DATA_FOUND. The period argument accepts the literals 'YEAR', 'SEMIYEAR', 'QUARTERYEAR', 'BIMONTH', and 'MONTH', and drives selection of the appropriate period view.
  • GET_PERIOD_END_DATE — The complementary function, returning the end date of the period in which the given date falls. Used together with GET_PERIOD_START_DATE to derive complete period boundaries.

Both functions use package-level global variables (g_start_date, g_end_date, g_ip_start_date, g_ip_end_date, g_ip_start_period, g_ip_end_period) to cache the most recent invocation. When the incoming date and period match the cached input, the cached result is returned without re-querying; otherwise the cache is flushed and the lookup is re-executed. This caching reduces repeated queries when the same period is resolved across many rows.

Tables Accessed

The package reads exclusively from HRI time period views, one per supported granularity. The documented views are HRI_TIME_YEAR_V, HRI_TIME_SEMIYEAR_V, HRI_TIME_QTR_V, HRI_TIME_BIMONTH_V, and HRI_TIME_MONTH_V. Each view presents start_date and end_date columns, and the function applies a BETWEEN predicate on the input date to identify the containing period. These views encapsulate the enterprise's period definitions and are read-only from the package's perspective; no DML is performed. Because the package accesses them through APPS synonyms, it inherits standard EBS schema and privilege conventions.

Usage Notes

HRI_BPL_TIME is an internal business-layer package and is not exposed as a concurrent program or form-bound API. The documented metadata records no other packages referencing it, which indicates it is invoked directly by HRMS product code and by custom extensions rather than through a documented public API chain. Typical invocation patterns include custom SQL and PL/SQL that must align HR transactions or balances to standard reporting periods, and Oracle-delivered analytics logic that buckets data by month, bimonth, quarter, semiyear, or year.

Developers integrating with this package should note two behaviors. First, callers must pass a valid period literal; unrecognized values do not resolve to a calendar and the lookup will fail. Second, the function raises NO_DATA_FOUND for NULL inputs, so custom code should validate arguments or handle the exception. Because the package caches state in global variables, callers should not assume thread-level isolation beyond what Oracle session semantics provide. For EBS 12.1.1 and 12.2.2, the package remains an APPS-owned, read-only utility suitable for direct call from custom PL/SQL where standard period boundary derivation is required.