Results for “ap_charges_v”
20 results
AI-generated from documented ETRM metadata — verify critical details on the linked pages.
Overview
AP_CHARGES_V is a read-only view owned by the APPS schema in Oracle E-Business Suite Payables (AP). It exposes the non-inventory charge lines recorded against an invoice — specifically tax, freight, and miscellaneous distribution lines — in a flattened, report-friendly format. In EBS 12.1.1 and 12.2.2, the view serves as a convenient abstraction over AP_INVOICE_DISTRIBUTIONS, joining distribution rows to their distribution type description and, where present, their tax code, so that charge detail can be queried without manually decoding lookup codes or performing the outer join to the tax code table each time.
The view's principal role is reporting and integration. Because it filters on LINE_TYPE_LOOKUP_CODE IN ('TAX', 'FREIGHT', 'MISCELLANEOUS'), it isolates the charge-bearing portion of an invoice's distribution set from the item, accrual, and other line types that also reside in the base table. The status of the object is VALID in the documented environment (ETRM 12.2.2), confirming it is a supported, compiled view. Reporting tools, custom concurrent programs, and downstream extracts use it to reconcile tax and freight amounts posted to Accounts Payable without extracting the entire distribution population.
Underlying Base Objects
The documented metadata identifies four referenced objects: AP_INVOICE_DISTRIBUTIONS (exposed as a synonym), AP_LOOKUP_CODES (a view), AP_TAX_CODES (synonym), and the FND_GLOBAL package.
- AP_INVOICE_DISTRIBUTIONS — the primary source table supplying invoice, distribution, amount, accounting, and audit columns. Each row of the view corresponds to one qualifying distribution row.
- AP_LOOKUP_CODES — supplies the DISPLAYED_FIELD value for the distribution type, driven by the lookup type 'INVOICE DISTRIBUTION TYPE' and matched on LOOKUP_CODE against LINE_TYPE_LOOKUP_CODE. This is an inner join, so only distribution types defined as lookups appear.
- AP_TAX_CODES — supplies the tax code NAME and is joined with an outer join (+) on TAX_CODE_ID, allowing freight and miscellaneous lines (which carry no tax code) to remain in the result set.
- FND_GLOBAL — the standard EBS package referenced in the view metadata, typically for multi-org or session context resolution applied through the underlying base objects.
The view text was constructed with the older Oracle outer-join syntax (+), consistent with pre-12c database compatibility in EBS 12.1.1 and 12.2.2 environments.
Key Columns
- INVOICE_ID — identifier of the parent invoice.
- CHARGE_DISTRIBUTION_ID — the underlying invoice distribution identifier for the charge line.
- CHARGE_TYPE_LOOKUP_CODE — the LINE_TYPE_LOOKUP_CODE value: TAX, FREIGHT, or MISCELLANEOUS.
- CHARGE_TYPE — the human-readable description from AP_LOOKUP_CODES.DISPLAYED_FIELD.
- TAX_CODE / TAX_ID — the tax code name and identifier, populated only for tax lines.
- CHARGE_CCID — the distribution code combination (accounting flexfield) charged for the line.
- DESCRIPTION — free-text description entered on the distribution.
- CHARGE_AMOUNT and CHARGE_BASE_AMOUNT — the entered and functional-currency amounts of the charge.
- EXCHANGE_RATE — the rate applied where the invoice currency differs from the functional currency.
- Audit columns — LAST_UPDATE_DATE, LAST_UPDATED_BY, CREATION_DATE, CREATED_BY, PROGRAM_ID, REQUEST_ID, and related fields for lineage and troubleshooting.
Common Use Cases and Queries
Typical scenarios include reconciling tax and freight charges per invoice, feeding charge detail into tax reporting, and auditing miscellaneous distributions. A representative query listing charges for a given invoice:
SELECT invoice_id, charge_type, charge_amount, charge_base_amount, tax_code, description FROM ap_charges_v WHERE invoice_id = :p_invoice_id ORDER BY charge_type;SELECT charge_type, SUM(charge_base_amount) FROM ap_charges_v WHERE invoice_id IN (SELECT invoice_id FROM ap_invoices_all WHERE vendor_id = :p_vendor) GROUP BY charge_type;SELECT invoice_id, tax_code, SUM(charge_amount) FROM ap_charges_v WHERE charge_type_lookup_code = 'TAX' GROUP BY invoice_id, tax_code;
Because charges are tied to the distribution rather than the invoice header, AP_CHARGES_V is the appropriate source whenever tax, freight, or miscellaneous amounts must be reported at grain finer than the invoice. This aligns with standard freight and miscellaneous distributions, which post to the same code combination as the related invoice line when GL Date and Account options are inherited.
-
View: AP_CHARGES_V 12.2.2
APPS.AP_CHARGES_V·↳ AP_INVOICE_DISTRIBUTIONS·↳ AP_LOOKUP_CODES·↳ AP_TAX_CODES·Explore AP module →
-
View: AP_CHARGES_V 12.1.1
APPS.AP_CHARGES_V·↳ AP_INVOICE_DISTRIBUTIONS·↳ AP_LOOKUP_CODES·↳ AP_TAX_CODES·Explore AP module →
-
VIEW: APPS.AP_CHARGES_V 12.2.2
-
VIEW: APPS.AP_CHARGES_V 12.1.1
-
SYNONYM: APPS.AP_TAX_CODES 12.2.2
-
12.1.1 DBA Data 12.1.1
-
SYNONYM: APPS.AP_TAX_CODES 12.1.1
-
12.2.2 DBA Data 12.2.2
-
12.2.2 FND Design Data 12.2.2
-
12.1.1 FND Design Data 12.1.1
-
VIEW: APPS.AP_LOOKUP_CODES 12.1.1
-
VIEW: APPS.AP_LOOKUP_CODES 12.2.2
-
Set Distribution Table.
-
Set Distribution Table.
-
12.2.2 DBA Data 12.2.2
-
12.1.1 DBA Data 12.1.1
-
Set Distribution Table.
-
Set Distribution Table.