Search Results tp_document_purpose_code




Overview

The ECE_CDMO_HEADER_V view in the APPS schema is a private view owned by the e-Commerce Gateway (EC) product, designed to extract header information for the outbound Credit/Debit Memo (812/CREADV/DEBADV) transaction in Oracle EBS 12.1.1 and 12.2.2. In the EDI transaction set 812, CREADV represents a Credit Adjustment and DEBADV a Debit Adjustment, both used to communicate credit or debit memo activity to trading partners. The view is registered as a business entity under the AR product with the display name "Credit/Debit Memo Header View." It acts as the data source for the outbound EDI mapping layer, feeding the flat-file generation processes that produce the 812 transaction. Users researching the column tp_document_purpose_code will find that this attribute is explicitly projected as TO_CHAR(NULL) TP_DOCUMENT_PURPOSE_CODE, meaning it is a placeholder that returns NULL and carries no data in the current implementation. Understanding this is important because the column is present in the view's projection for downstream mapping compatibility but is intentionally non-populated.

Underlying Base Objects

The view is defined over a large join of AR, HZ, and EC base objects. The documented referenced objects include RA_CUSTOMER_TRX (the primary transaction header), RA_CUST_TRX_TYPES, AR_PAYMENT_SCHEDULES, AR_BATCH_SOURCES, AR_SYSTEM_PARAMETERS, and RA_TERMS/RA_TERMS_LINES for payment terms. Customer and party information is sourced from HZ_CUST_ACCOUNTS, HZ_CUST_ACCT_SITES_ALL, HZ_CUST_SITE_USES_ALL, HZ_LOCATIONS, HZ_PARTIES, HZ_PARTY_SITES, HZ_ORG_CONTACTS, and HZ_RELATIONSHIPS. EDI trading partner configuration comes from ECE_TP_HEADERS and ECE_TP_DETAILS, while accounting context is drawn from GL_SETS_OF_BOOKS and RA_SALESREPS. The view text begins with a constant 'EDI' COMMUNICATION_METHOD and derives DOCUMENT_TYPE via a DECODE on RA_CUST_TRX_TYPES.TYPE, mapping credit memos (CM) to either 'OACM' or 'CM' depending on whether a previous customer transaction exists.

  1. Transaction entity: RA_CUSTOMER_TRX with alias RCT1.
  2. Trading partner: ECE_TP_HEADERS (ETH) and ECE_TP_DETAILS (ETD).
  3. Customer/party: HZ tables (CA1, CAS1, PT1, LOC1, PTS1).

Key Columns

The view exposes EDI-oriented and business columns. The DOCUMENT_TYPE column is derived from the transaction type to distinguish credit and debit memos. TP_DOCUMENT_ID, TP_TRANSLATOR_CODE, TP_LOCATION_CODE_EXT, TP_DESCRIPTION, TP_REFERENCE_EXT1, and TP_REFERENCE_EXT2 are trading partner attributes sourced from the ECE tables. TP_DOCUMENT_PURPOSE_CODE is returned as NULL. TP_DOCUMENT_CODE is populated from RCT1.TRX_NUMBER, providing the document number for the memo. TRANSACTION_DATE is set to SYSDATE. Bill-to fields include BILL_TO_CUSTOMER_CODE_INT, BILL_TO_CUSTOMER_NAME, address components (ADDRESS1-4, CITY, POSTAL_CODE, COUNTRY, STATE, PROVINCE, COUNTY), BILL_TO_CUSTOMER_SIC_CODE, BILL_TO_CUSTOMER_SALES_CHANNEL, and contact fields such as last name, first name, and job title. Attribute flexfield columns (TPD_ATTRIBUTE_CATEGORY, TPD_ATTRIBUTE1ATTRIBUTE5) and customer attribute columns allow extensibility. The projection also includes TEST_FLAG and COMMUNICATION_METHOD.

Common Use Cases and Queries

This view is primarily consumed by the e-Commerce Gateway outbound 812 process rather than by end-user reporting. A typical diagnostic query inspects the header data for a specific transaction and confirms whether the purpose code is populated.

  • Verify purpose code behavior: SELECT TP_DOCUMENT_CODE, DOCUMENT_TYPE, TP_DOCUMENT_PURPOSE_CODE FROM ECE_CDMO_HEADER_V WHERE TP_DOCUMENT_CODE = '12345'; — returns NULL for purpose code by design.
  • Identify credit vs. debit memos: SELECT TP_DOCUMENT_CODE, DOCUMENT_TYPE, TRANSACTION_DATE FROM ECE_CDMO_HEADER_V;
  • Trading partner audit: SELECT TP_TRANSLATOR_CODE, TP_LOCATION_CODE_EXT, TP_DESCRIPTION FROM ECE_CDMO_HEADER_V;

Because tp_document_purpose_code is a NULL placeholder, report developers requiring a meaningful purpose value must derive it from RA_CUST_TRX_TYPES or transaction attributes, or customize the view. Care should be taken, as schema-level changes to a seeded EC view affect the outbound mapping.

  • View: ECE_CDMO_HEADER_V 12.2.2

    owner:APPS,  object_type:VIEW,  fnd_design_data:EC.ECE_CDMO_HEADER_V,  object_name:ECE_CDMO_HEADER_V,  status:VALID,  product: EC - e-Commerce Gatewaydescription: This view extracts header informationfor the outbound Credit/Debit Memo (812/CREADV/DEBADV) transaction.@rep:scope private@rep:product AR@rep:lifecycle active@rep:displayname Credit/Debit Memo Header View@rep:category BUSINESS_ENTITY AR_CRE ,  implementation_dba_data: APPS.ECE_CDMO_HEADER_V

  • View: ECE_INO_HEADER_V 12.1.1

    owner:APPS,  object_type:VIEW,  fnd_design_data:EC.ECE_INO_HEADER_V,  object_name:ECE_INO_HEADER_V,  status:VALID,  product: EC - e-Commerce Gatewaydescription: This view extracts header informationfor the outbound Invoice (810/INVOIC) transaction.@rep:scope private@rep:product AR@rep:lifecycle active@rep:displayname Invoice Header View@rep:category BUSINESS_ENTITY AR_INVOICE ,  implementation_dba_data: APPS.ECE_INO_HEADER_V

  • View: ECE_INO_HEADER_V 12.2.2

    owner:APPS,  object_type:VIEW,  fnd_design_data:EC.ECE_INO_HEADER_V,  object_name:ECE_INO_HEADER_V,  status:VALID,  product: EC - e-Commerce Gatewaydescription: This view extracts header informationfor the outbound Invoice (810/INVOIC) transaction.@rep:scope private@rep:product AR@rep:lifecycle active@rep:displayname Invoice Header View@rep:category BUSINESS_ENTITY AR_INVOICE ,  implementation_dba_data: APPS.ECE_INO_HEADER_V

  • View: ECE_CDMO_HEADER_V 12.1.1

    owner:APPS,  object_type:VIEW,  fnd_design_data:EC.ECE_CDMO_HEADER_V,  object_name:ECE_CDMO_HEADER_V,  status:VALID,  product: EC - e-Commerce Gatewaydescription: This view extracts header informationfor the outbound Credit/Debit Memo (812/CREADV/DEBADV) transaction.@rep:scope private@rep:product AR@rep:lifecycle active@rep:displayname Credit/Debit Memo Header View@rep:category BUSINESS_ENTITY AR_CRE ,  implementation_dba_data: APPS.ECE_CDMO_HEADER_V