Results for “range_amount_basis”

10 results




AI-generated from documented ETRM metadata — verify critical details on the linked pages.

Overview

AP_TAX_CODES_ALL is the master tax code definition table in the Oracle Payables (AP) module. It stores the tax codes used to calculate, default, and account for tax on invoices, purchase orders, and requisitions across Oracle E-Business Suite 12.1.1 and 12.2.2. Each row represents a tax code scoped to a set of books (ledger), carrying the default tax type, rate, recovery rules, withholding attributes, and the accounting flexfield combination used to post the tax amount. The table is owned by the AP schema and is validated in ETRM.

Because AP_TAX_CODES_ALL is referenced by multiple downstream transaction and tax-engine tables, and references several setup tables, the heuristic Data Vault classification derived from its foreign key structure is hub-leaning. In modeling terms, TAX_ID can be treated as a durable business key (hub) candidate, with descriptive rate, flag, and attribute columns best represented as a satellite surrounding that hub.

Key Information Stored

The surrogate primary key is TAX_ID, enforced by AP_TAX_CODES_PK and backed by the unique index AP_TAX_CODES_U1. TAX_ID also serves as the documented business-key candidate. The most significant columns include:

Standard WHO audit columns (CREATION_DATE, CREATED_BY, LAST_UPDATE_DATE, LAST_UPDATED_BY, LAST_UPDATE_LOGIN) and the ATTRIBUTE1–15 and GLOBAL_ATTRIBUTE1–20 descriptive flexfields are also present.

Common Use Cases and Queries

Typical uses include listing active tax codes by ledger, resolving a tax code name to its accounting combination, and reconciling tax lines on invoices.

Retrieve active tax codes for a ledger:

  • SELECT tax_id, name, tax_type, tax_rate FROM ap_tax_codes_all WHERE set_of_books_id = :ledger_id AND enabled_flag = 'Y' AND (inactive_date IS NULL OR inactive_date > SYSDATE);

Join tax codes to their accounting flexfield:

  • SELECT t.name, c.concatenated_segments FROM ap_tax_codes_all t JOIN gl_code_combinations_kfv c ON t.tax_code_combination_id = c.code_combination_id WHERE t.tax_id = :tax_id;

Trace tax codes used on invoice distributions:

  • SELECT d.invoice_id, d.tax_code_id, t.name, d.amount FROM ap_invoice_distributions_all d JOIN ap_tax_codes_all t ON d.tax_code_id = t.tax_id WHERE d.invoice_id = :invoice_id;

Because the table is a hub, reporting queries frequently join it outward to ZX_ID_TCC_MAPPING_ALL (via TAX_RATE_CODE_ID) and ZX_LINES_DET_FACTORS (via HISTORICAL_TAX_CODE_ID) when the E-Business Tax engine is enabled in Release 12.

Related Objects

The following dependencies are most significant:

  • AP_INVOICE_DISTRIBUTIONS_ALL.TAX_CODE_ID → AP_TAX_CODES_ALL — links posted invoice tax lines to their defining code.
  • ZX_ID_TCC_MAPPING_ALL.TAX_RATE_CODE_ID → AP_TAX_CODES_ALL — the E-Business Tax mapping between tax regimes/rates and legacy tax codes.
  • ZX_LINES_DET_FACTORS.HISTORICAL_TAX_CODE_ID → AP_TAX_CODES_ALL — preserves historical tax code context for tax lines.
  • PO_LINE_LOCATIONS_ALL.TAX_CODE_ID → AP_TAX_CODES_ALL — defaults tax on purchasing documents.
  • PO_REQUISITION_LINES_ALL.TAX_CODE_ID → AP_TAX_CODES_ALL — supplies tax defaults on requisition lines.
  • AP_TAX_CODES_ALL.OFFSET_TAX_CODE_ID → AP_TAX_CODES_ALL — self-referencing offset/paired tax code.
  • AP_TAX_CODES_ALL.SET_OF_BOOKS_ID → GL_SETS_OF_BOOKS_11I and TAX_CODE_COMBINATION_ID → GL_CODE_COMBINATIONS — ledger and accounting references.
  • AP_TAX_RECVRY_RULES_ALL via TAX_RECOVERY_RULE_ID and withholding parties PO_VENDORS / PO_VENDOR_SITES_ALL supply recovery and withholding context.