Search Results c_segment_overirdeformula
Overview
GL_RGXRPTD_XMLP_PKG is the generated PL/SQL package that implements the server-side logic of the Oracle General Ledger report "RGXRPTD" (a General Ledger report program produced through the Oracle Reports XML Publisher integration). In Oracle EBS 12.1.1 and 12.2.2, concurrent programs that are built on Oracle Reports with an XML Publisher template generate a corresponding PL/SQL package of this form, conventionally suffixed with _XMLP_PKG. The package encapsulates the report's concurrent program parameters, its constants, and the procedural hooks that the Reports engine fires during execution.
The business function served is the extraction and formatting of General Ledger segment-related data, particularly report rows whose segmentation is derived from an access set. The package supplies the report with the identity of the target accounting structure and the GL key flexfield context, resolves segment override values supplied at runtime, and controls the before/after execution flow of the report. The constants declared in the specification (C_ID_FLEX_CODE set to 'GL#', C_INDUSTRY_TYPE set to 'C', and C_ATTRIBUTE_FLAG set to 'N') fix the package to the standard GL Accounting Flexfield definition, ensuring the report addresses the correct key flexfield structure regardless of session state.
The package is documented in ETRM with the API classification OTHER, indicating it is not a formal public API but an internal, report-owned artifact. The specification header records it as a noship source with a 2007 revision stamp, consistent with the long-lived, rarely modified nature of generated report packages.
Key Procedures and Functions
Eight documented program units make up the package.
- BeforeReport — the standard Oracle Reports before-report trigger. It executes initialization logic prior to data retrieval, typically validating or deriving parameter values and populating package globals used by the report query.
- AfterReport — the standard after-report trigger, invoked on completion of the report for cleanup or final-state handling.
- c_segment_overirdeformula — accepts a segment override value and returns a character result. This is the unit directly associated with the user's search term. It implements the report's segment override formula, translating or normalizing a segment override input into the form the report requires.
- f_override_segment — a helper function that takes a segment value and returns a varchar2, providing the lower-level override resolution used by the report's formatting logic.
- C_STRUCTURE_ID_p — accessor returning the accounting structure identifier, backed by the
C_STRUCTURE_IDpackage variable. - C_ID_FLEX_CODE_p — accessor returning the key flexfield code (
GL#). - C_INDUSTRY_TYPE_p — accessor returning the industry type constant.
- C_ATTRIBUTE_FLAG_p — accessor returning the attribute flag constant.
The four _p accessors are generated wrappers that expose package-level constants and variables to the Oracle Reports layout and query definitions, since Reports cannot reference PL/SQL package variables directly.
Tables Accessed
The package references two tables through APPS synonyms.
- GL_ACCESS_SETS — read to resolve the access set identified by the report parameter
P_ACCESS_SET_ID. The access set determines the hierarchy of account ranges used to restrict report content, and its structure identifier is what theC_STRUCTURE_IDvariable ultimately reflects. - GL_LEDGERS — read to establish ledger context, including the chart of accounts and therefore the key flexfield structure under which the segment overrides are interpreted.
No writes are documented; the package functions as a read-only reporting helper over GL configuration data.
Usage Notes
GL_RGXRPTD_XMLP_PKG is not invoked directly by application forms or by customer code. It is generated and owned by the RGXRPTD concurrent program and is executed by the Oracle Reports runtime whenever that program is submitted, whether from the Standard Request Submission form, the Submit Requests concurrent program, or an XML Publisher-enabled report launch. Substitution parameters declared in the specification — P_ACCESS_SET_ID, P_REPORT_ID, P_CONC_REQUEST_ID, and P_DELIMITER — are populated by the Reports engine from the concurrent program's parameter list at submission time.
Because it is an internal report package and is referenced by zero other packages, it should not be called from custom PL/SQL. Code that requires segment override behavior should call supported GL APIs instead. Any modification to this package would be overwritten by patching, as the source header marks it as a non-shipped but version-controlled generated unit.