Search Results get_remaining_saved_pay
Overview
PAY_SE_HOLIDAY_PAY is an Oracle E-Business Suite Payroll (PAY) package owned by the APPS schema. It encapsulates the Swedish localization business rules governing holiday pay, vacation entitlement, absence accounting, and saved (deferred) holiday balances. The package resolves questions that arise during payroll calculation and absence processing: how many working days fall within an earning year, whether an employee is entitled to holiday pay for a given period, how many of those days are paid versus unpaid, how many vacation days have accrued, and what limits apply to saved or advanced holiday balances.
The functions rely on effective-dated assignment and people records, payroll element definitions, and user-defined payroll tables, allowing the calculation logic to be driven by legislative and configuration data rather than hard-coded constants. Because the logic is date-effective and assignment-based, the same function can be invoked for a retroactive recalculation as for a current-period run without changing its interface.
Key Procedures and Functions
The package exposes approximately thirty-three documented functions. The most significant groups are described below; parameters are not reproduced here, but the purposes are as documented.
- GET_EARNING_YEAR_WORKINGDAYS — returns the count of working days in the earning year for an assignment at a given effective date, forming the denominator for many holiday calculations.
- CHECK_ENTITLEMENT — evaluates whether holiday entitlement exists for a pay period and returns the corresponding earning start and end dates as output values.
- GET_PAID_UNPAID_DAYS — determines the split between paid holiday days, unpaid holiday days, and total working days. This function accepts p_tax_unit_id alongside the assignment, assignment action, and earning period dates, plus output parameters for the three day counts.
- GET_CALCULATION_OPTION — returns the calculation option applicable to an assignment, local unit, tax unit, and absence category, and optionally returns a vacation indicator.
- GET_END_YEAR — computes the earning year end for a date earned within a specified tax unit.
- GET_SAVED_HOLIDAY_LIMIT and GET_SAVED_YEAR_LIMIT_LEVEL — retrieve saved holiday limits and identify the level (legal employer, person, or assignment) at which the saved-year limit is defined.
- GET_VACATION_DAYS — calculates vacation days for a payroll period.
- CHECK_ADVANCE_HOLIDAY_LIMIT — validates whether an advance holiday draw exceeds the permitted limit.
- GET_REMAINING_SAVED_PAY, GET_SICKNESS_DAYS, GET_CALENDAR_DAYS, COMPENSATION_ENTITLEMENT, GET_CY_START_DATE, and GET_CY_PAID_UNPAID_DAYS — support remaining-balance, sickness, calendar-day, compensation, and calendar-year computations.
- ELEMENT_EXIST, GET_HOURLY_SALARIED_CODE, GET_ASSG_STATUS, and UPDATE_ENTITLEMENT_RAN — provide element existence checks, hourly/salaried classification, assignment status retrieval, and entitlement processing state updates.
Tables Accessed
The package reads configuration and transactional payroll data through APPS synonyms. Assignment and person context come from PER_ALL_ASSIGNMENTS_F and PER_ALL_PEOPLE_F. Payroll element metadata is drawn from PAY_ELEMENT_TYPES_F, PAY_ELEMENT_LINKS_F, PAY_ELEMENT_ENTRIES_F, PAY_ELEMENT_ENTRY_VALUES_F, and PAY_INPUT_VALUES_F. User-defined configuration is read from PAY_USER_TABLES and PAY_USER_ROWS_F, with Fast Formula support provided by FF_DATABASE_ITEMS, FF_GLOBALS_F, and FF_USER_ENTITIES. Organization-level holiday rules are read from HR_ORGANIZATION_INFORMATION and HR_SOFT_CODING_KEYFLEX, while absence categories are resolved from PER_ABSENCE_ATTENDANCE_TYPES. The tax unit parameter (p_tax_unit_id) links these rules to the applicable legal employer or tax reporting unit.
Usage Notes
PAY_SE_HOLIDAY_PAY is a server-side localization package rather than a public API. It is normally invoked indirectly by Swedish payroll Fast Formulas, absence and holiday element processing, and oracle payroll calculation routines that need entitlement or saved-balance values. It is also referenced by one other APPS package, indicating reuse within the Swedish payroll subsystem. Custom code should call these functions only where no supported API exists, and must respect the effective-date and assignment context parameters, since results are period-sensitive and payroll-affecting.