Search Results pa_agreements




Overview

PA_AGREEMENTS is a single-organization reporting view in the Oracle Projects (PA) module of Oracle E-Business Suite, documented in ETRM under the same title. It presents project and customer agreement data — such as contract agreements, funding agreements, and customer agreements — in a form scoped to the organization of the active session. The view is a filtered projection of the multi-organization table PA_AGREEMENTS_ALL, and its defining characteristic is the row-level security predicate applied through the ORG_ID column. The predicate reads the organization identifier from the client environment (USERENV('CLIENT_INFO')) and restricts returned rows to agreements belonging to that organization, substituting a value of -99 when no organization context can be derived.

Because the view is described as "Single-Org," it serves as the organization-scoped access path for agreement data, whereas PA_AGREEMENTS_ALL contains agreements across all operating units. In the ETRM 12.2.2 metadata, the view is recorded with no owner and no documented referenced base objects, and implementation notes state that it is not implemented in the reference database from which the excerpt was taken. Its role in reporting and integration is therefore that of a conventional MOAC-aware (Multi-Org Access Control) view: application logic and custom reports may query PA_AGREEMENTS when the intent is to see only agreements for the currently selected operating unit.

Underlying Base Objects

The documented view text selects from a single base object, PA_AGREEMENTS_ALL:

SELECT ... FROM PA_AGREEMENTS_ALL WHERE NVL(ORG_ID, ...) = NVL(TO_NUMBER(DECODE(SUBSTR(USERENV('CLIENT_INFO'),1,1),' ',NULL,SUBSTR(USERENV('CLIENT_INFO'),1,10))), -99)

No other base tables or views are documented in the ETRM metadata. The relationship between the view and the base table is a straightforward projection: all columns enumerated in the view text map one-to-one to columns of PA_AGREEMENTS_ALL, and the view adds only the ORG_ID filter. The filter uses the standard EBS client-information mechanism, parsing the first ten characters of the CLIENT_INFO value to yield the organization identifier. When the session supplies no organization, the expression collapses to -99, which typically returns no agreements.

Key Columns

The view exposes the following columns, which correspond directly to PA_AGREEMENTS_ALL. The important identifiers and business attributes include:

Common Use Cases and Queries

The view is typically used in organization-scoped reporting. A basic query lists active agreements for the session organization:

SELECT agreement_id, agreement_num, customer_id, agreement_type,
       amount, agreement_currency_code, expiration_date
FROM   pa_agreements
WHERE  NVL(expiration_date, SYSDATE + 1) > SYSDATE;

Aggregation by type is common for funding analysis:

SELECT agreement_type, COUNT(*) agreements, SUM(amount) total_amount
FROM   pa_agreements
GROUP  BY agreement_type;

Joining to customer and organization references supports contract reporting:

SELECT a.agreement_num, a.amount, c.customer_name
FROM   pa_agreements a, ra_customers c
WHERE  a.customer_id = c.customer_id;

Because the view is organization-restricted, reports intended for cross-organization analysis must query PA_AGREEMENTS_ALL instead, or ensure that the correct operating unit is set in the session. The flexfield attributes are frequently extracted for custom descriptive reporting.