Search Results get_criteria




Overview

The APPS.PA_EXPENDITURE_INQUIRY package is a global PL/SQL package within the Oracle E-Business Suite Projects (PA) module. It is declared with AUTHID CURRENT_USER and owns a set of public global variables that act as a shared runtime context for the Expenditure Inquiry inquiry-only form (and any dependent views or program units). The package functions as a session-scoped state container: values such as the calling mode, the current expenditure item identifier, the query criteria, the source distribution type, and the application identifier are stored in package globals and exposed through getter functions so that the form's database views can filter or join records appropriately. It is classified as OTHER in the ETRM repository, indicating it is not a public business API but an internal form-support package. The package is referenced by five other packages and carries historical bug references (Bug# 680401 and Bug# 9929147), reflecting its evolution across releases including 12.1.1 and 12.2.2.

Key Procedures and Functions

  • GET_MODE — Returns the current calling mode from the package global X_Calling_Mode; used by views to determine display behavior.
  • GET_EXPENDITURE_ITEM_ID — Returns the current expenditure item identifier (X_expenditure_item_id) to consuming views and queries.
  • GET_CRITERIA — Returns the package global X_Query_criteria, the value that drives the query filter for expenditure inquiry (associated with Bug# 680401).
  • PA_EXPENDITURE_INQUIRY_DRIVER — Sets the calling mode global based on input passed from the form.
  • PA_EXPENDITURE_ITEM_DRIVER — Populates the expenditure item identifier global in the package context.
  • PA_SOURCE_DIST_TYPE_DRIVER — Sets the source distribution type global (added for Bug# 9929147).
  • PA_APPLICATION_ID_DRIVER — Sets the application identifier global (added for Bug# 9929147).
  • GET_APPLICATION_ID — Returns the stored application identifier.
  • GET_SOURCE_DIST_TYPE — Returns the stored source distribution type.
  • PA_EXPENDITURE_CRITERIA_DRIVER — Sets the query criteria global passed from the form (Bug# 680401).
  • PA_GET_CDL_DETAILS — Retrieves cost distribution line detail attributes for a given expenditure item, returning vendor identifier and system reference values.

The getter functions carry RESTRICT_REFERENCES (WNDS, WNPS) pragmas, allowing them to be referenced directly inside SQL statements and views.

Tables Accessed

  • PA_EXPENDITURE_ITEMS_ALL — The primary transaction table for expenditure items; the package resolves item identifiers and detail attributes from it.
  • PA_EXPENDITURES_ALL — The expenditure header/detail table joined to retrieve expenditure context for inquiry.
  • PA_COST_DIST_LINES_ALL_BAS — The cost distribution lines base table, queried by PA_GET_CDL_DETAILS to return vendor and system reference information.

Access is performed through APPS synonyms, consistent with the package's AUTHID CURRENT_USER declaration and the EBS schema design.

Usage Notes

The package is invoked primarily by the Expenditure Inquiry form in oracle Projects. The form calls the various *_DRIVER procedures to push user-selected context values (mode, item, criteria, application, distribution type) into the package globals, after which the inquiry views call GET_MODE, GET_CRITERIA, GET_EXPENDITURE_ITEM_ID, GET_APPLICATION_ID, and GET_SOURCE_DIST_TYPE to construct result sets dynamically. PA_GET_CDL_DETAILS is used to drill into cost distribution details for a selected expenditure item. Because it is not a public API, custom code should query the underlying tables directly rather than depend on this package; any client extension that does reference it must be aware that the global variables are session-scoped and must be reinitialized for each inquiry. The package is compatible with both 12.1.1 and 12.2.2, and the presence of the NOCOPY hint and bug-tagged additions confirms it has been maintained for online performance and correctness.