Search Results edi_flag




Overview

OP_CUST_MST_V is a PL/SQL view owned by the APPS schema in Oracle E-Business Suite, defined within the GML — Process Manufacturing Logistics product family. The view description states that it is a "View of op_cust_mst for OPM OF customers," indicating that it exposes a customer master record set scoped to Oracle Process Manufacturing (OPM) Order Fulfillment usage. In EBS 12.1.1 and 12.2.2 the object retains VALID status and is treated as a reporting and integration surface rather than a transactional entry point.

The view's primary role is to reconcile the Oracle Receivables Trading Community Architecture (TCA) model — where a customer is composed of a party, an account, and one or more account sites with site uses — into a flatter, legacy-shaped customer master structure. Because the search term "bill_to" appears in the query text, the view is of particular interest to users looking up billing site identifiers. Specifically, the view filters on SITE_USE_CODE IN ('BILL_TO', 'SHIP_TO'), and it emits distinct column pairs that separate the BILL_TO site from the SHIP_TO site for each returned row.

Underlying Base Objects

The view is defined over five documented base objects and one package reference:

Joins are made on CUST_ACCOUNT_ID, CUST_ACCT_SITE_ID, SITE_USE_ID, ORG_ID, and PARTY_ID, with the SITE_USE_CODE restricted to the two billing and shipping values.

Key Columns

The documented column list includes CUST_ID, CUST_NO, ADDR_ID, CUSTSORT_NO, CUST_NAME, PHONE_NO, and FAX. Beyond this published list, the view text exposes several computed or aliased columns that are functionally significant:

  • CUST_ACCT_SITE_ID — the site-level identifier, which is re-emitted several times and also returned a second time in the trailing position of the SELECT list.
  • ACCOUNT_NUMBER — the customer account number from HZ_CUST_ACCOUNTS.
  • The concatenated ACCOUNT_NUMBER || delimiter || S.LOCATION — the composite customer/address display key, using the GL$CUST_DELIMITER profile value (defaulting to '-').
  • DECODE(C.STATUS...) and the nested DECODE on A.STATUS and S.STATUS — a single-column "inactive" flag returning 1 when any of the account, site, or site-use statuses are 'I'.
  • Two dedicated flags derived from SITE_USE_CODE equal to 'BILL_TO' and 'SHIP_TO' — each returns 1 only when the site-use code matches and both the site-use and account statuses are 'A' (active).
  • BILL_TO-specific columns — DECODE(S.SITE_USE_CODE, 'BILL_TO', A.CUST_ACCT_SITE_ID, NULL) and DECODE(S.SITE_USE_CODE, 'BILL_TO', S.SITE_USE_ID, NULL) yield the billing account site ID and site use ID respectively.
  • SHIP_TO-specific columns — parallel DECODEs yield the shipping account site ID and site use ID.
  • ORG_ID — the inventory organization, sourced from HZ_CUST_SITE_USES_ALL.

Because the SELECT list is dominated by NULL placeholders, the view presents a fixed-width legacy layout in which most positions are reserved for compatibility with the original op_cust_mst structure.

Common Use Cases and Queries

The view is typically used to resolve billing and shipping addresses for a customer account without traversing the full TCA hierarchy, and to identify parties with an active BILL_TO site. A representative query for locating billing sites is:

  • SELECT CUST_NO, CUST_NAME, ADDR_ID FROM APPS.OP_CUST_MST_V WHERE CUST_NO = :account_number;
  • Joining on ORG_ID to restrict results to a specific operating organization, since ORG_ID is carried through from HZ_CUST_SITE_USES_ALL and cross-checked against GL_PLCY_MST.
  • Filtering on the BILL_TO flag column to isolate accounts that have an active billing site use, or comparing BILL_TO and SHIP_TO flags to detect accounts with mismatched billing and shipping activation states.

Because the logic keys entirely on SITE_USE_CODE, a customer with multiple BILL_TO site uses will produce multiple rows, and consumers must apply additional filtering or aggregation. The use of GL$CUST_DELIMITER and the SUBSTRB truncation on PARTY_NAME should also be considered when the view output is exported to fixed-length interfaces.