Search Results assembly_spec
Overview
APPS.WIP_WIPRERTG_XMLP_PKG is the generated PL/SQL package body that supports the Oracle E-Business Suite concurrent program "WIP Resource Exception/Rejection Trend Report" (short name WIPRERTG). The report is delivered as an XML Publisher (BI Publisher) report, and like all XML Publisher concurrent programs, its data model may be implemented as a PL/SQL package that uses Oracle Reports-style user exits and bind parameters to construct the SQL query executed at runtime. This package follows the standard XMLP naming convention where the report short name is appended with the "_XMLP_PKG" suffix.
The package encapsulates report-level initialization logic and several helper functions that dynamically build fragments of the report's WHERE clause based on the values entered by the user in the concurrent program's parameter form. In Oracle EBS 12.1.1 and 12.2.2, this pattern is typical for reports that need flexible filtering — such as selecting by assembly, production line, or a first-unit-start-date range — without forcing the user to enter every criterion.
Key Procedures and Functions
The ETRM metadata documents six procedures/functions in this package body:
- BEFOREREPORT — The standard "before report" trigger function. It captures the concurrent request ID via FND_GLOBAL.CONC_REQUEST_ID, and includes commented-out FND SRWINIT and FND FLEXSQL user exit calls. It returns TRUE, allowing report execution to proceed.
- ASSEMBLY_SPEC — Returns a character string containing a WHERE-clause fragment restricting the report to a specific assembly (WIP entity name). If the assembly parameter is null, it returns a blank string so no filter is applied.
- LINE_SPEC — Returns a WHERE-clause fragment restricting the report to a specific production line code. If the line code parameter is null, it returns a blank string.
- DATE_RANGE — Returns a WHERE-clause fragment that filters records on the FIRST_UNIT_START_DATE column. It handles three scenarios: a single from-date (greater than or equal), a from-date and to-date with equal values (exact date match), and a from-date with a later to-date (BETWEEN range). This is the function most closely associated with the user's "date_range" search.
- AFTERREPORT — The "after report" trigger function, typically used to release resources or clean up after the report completes.
- AFTERPFORM — The "after parameter form" trigger function, which executes after the user supplies parameters but before the report query runs. It is commonly used to validate or derive parameter values.
Tables Accessed
The ETRM metadata does not enumerate the tables directly referenced by this package. Based on the SQL fragments generated by the helper functions, the report queries the WIP resource/rejection trend data, joining work-in-process entities (WIP_ENTITIES, aliased as E), production lines (WIP_LINES, aliased as L), and a resource summary source (aliased as RS, exposing FIRST_UNIT_START_DATE). These are accessed via APPS synonyms. The helper functions themselves do not perform DML; they only return text used by the report's data model.
Usage Notes
This package is not intended for direct invocation by end users or custom code. It is executed indirectly when the WIP Resource Exception/Rejection Trend Report concurrent program is run from the Submit Requests form or via the FND_REQUEST.SUBMIT_REQUEST API. During execution, Oracle XML Publisher invokes BEFOREREPORT, then the parameter form is processed (AFTERPFORM), the data model query is assembled using the returned specification strings from ASSEMBLY_SPEC, LINE_SPEC, and DATE_RANGE, and finally AFTERREPORT is called. Because the search term "date_range" maps directly to the DATE_RANGE function documented here, users investigating date-filtering behavior in this report should note that the filter applies TRUNC to the FIRST_UNIT_START_DATE column and requires both start and end dates to be entered for a BETWEEN range; entering only one date produces an open-ended filter.