Search Results p_sort_option




Overview

SSP_SMPRPELR_XMLP_PKG is an Oracle E-Business Suite package body owned by APPS and classified under the ETRM as OTHER. It is the generated PL/SQL wrapper that backs an Oracle Reports XML Publisher (BI Publisher) report definition. The package encapsulates the report's processing logic: initializing report-level variables, resolving the display names of key parameters, and exposing placeholder functions that the report layout calls to retrieve derived values at runtime. The underlying report is associated with Oracle Payroll and, based on its parameters (payroll, business group, time period, consolidation set, session date, sort option), serves as a payroll-related listing or register extract. The source header indicates the file SMPRPELRB.pls, version 120.0, last revised in December 2007, and the package is not referenced by any other database package, confirming that its role is confined to serving its own report.

Key Procedures and Functions

The package documents eleven procedures and functions:

  • BEFOREREPORT — Executes prior to report execution. It invokes the sort-option validation trigger, assigns the session date to a report global, copies the sort option into the internal C_SORT_OPTION variable, and populates report-level globals for payroll name, business group name, time period name, and consolidation set name by querying the respective base tables. It returns TRUE to allow the report to proceed.
  • P_SORT_OPTIONVALIDTRIGGER — Validates and derives the P_SORT_OPTION parameter value by calling DERIVE_SORT_CRITERIA and assigning the result to P_SORT_OPTION_m, thereby resolving the effective sort criteria used by the report query.
  • DERIVE_SORT_CRITERIA — Returns the sort criteria string used to order report output. This is the operative logic behind the sort-option handling.
  • C_SQL_TRACEFORMULA — Report formula placeholder that returns NULL; retained as a stub for SQL trace formatting.
  • AFTERREPORT — Executes after report completion and returns TRUE; it serves as the post-processing hook.
  • C_BUSINESS_GROUP_NAME_P, C_REPORT_SUBTITLE_P, C_PAYROLL_NAME_P, C_CONSOLIDATION_SET_NAME_P, C_TIME_PERIOD_NAME_P, C_SORT_OPTION_P — Accessor functions that expose each corresponding package global to the report layout, allowing the XML template to display resolved names and values.

Tables Accessed

The package reads from the following documented tables via APPS synonyms:

  • PAY_CONSOLIDATION_SETS — Queried by consolidation_set_id to retrieve the consolidation set name for the report header.
  • PER_TIME_PERIODS — Queried by time_period_id to retrieve the payroll period name.

In addition, BEFOREREPORT selects the payroll name from PAY_PAYROLLS_X by payroll_id and resolves the business group name through HR_REPORTS.GET_BUSINESS_GROUP. A NO_DATA_FOUND exception handler suppresses errors when lookups return no rows, ensuring the report does not fail on missing reference data.

Usage Notes

This package is not intended for direct invocation by forms, concurrent programs, or custom code. It is executed automatically by the Oracle Reports runtime when the associated payroll report is run. Users interact with it indirectly through the report's parameter form, where they supply the business group, payroll, time period, consolidation set, session date, and sort option. The sort option is of particular interest: the value entered is validated and converted into concrete sort criteria by DERIVE_SORT_CRITERIA during the BeforeReport phase, and the resolved value is then exposed to the layout through C_SORT_OPTION_P. Because the package is referenced by no other package and its header records a 2007 revision, it should be treated as a static, report-bound artifact; any modification risks invalidating the report definition and should therefore be limited to Oracle-supported patching.