Search Results offset_factor
Overview
AP_TAX_ENGINE_PKG is the core PL/SQL tax calculation engine for Oracle Payables and Oracle Purchasing in Oracle E-Business Suite 12.1.1 and 12.2.2. The package body resides in the APPS schema and is classified as an OTHER API, reflecting its role as an internal engine rather than a formally published interface. Its principal business function is to compute tax for a document—invoice, requisition, purchase order, or shipment—returning both recoverable and non-recoverable tax amounts. Originally created by Fiona Purves in October 1998 and subsequently enhanced through several versions, the package embodies the EBS tax determination logic used by both Payables and Purchasing, including tax group handling implemented by Debasis Choudhuri in 2000 (Bug Fix 1076352). The header revision 120.3 (October 2005) indicates the shipped version aligned with the 12.x code line.
Key Procedures and Functions
The package exposes seven documented procedures and functions:
- CALCULATE_TAX — The primary public API. It calculates tax for a document when a view name and the document header ID, line ID, or shipment ID are supplied. If a transaction line ID is passed, it takes precedence over the header ID. It returns tax information for Purchasing requirements in a local PL/SQL table and also populates the global table g_tax_info_tbl. Requisition tax is computed in transaction currency, converted to functional currency via the Euro APIs, and stored in functional currency.
- SUM_TAX_GROUP_RATE — Accumulates or aggregates the tax rates belonging to a tax group, supporting the tax group functionality introduced in Bug Fix 1076352. This is the procedure referenced by the user search term "sum_tax_group_rate."
- COPY_RECORD — Copies a tax information record, used to duplicate records within the package's internal PL/SQL table structures.
- INITIALIZE_G_TAX_INFO_REC — Initializes the global tax information record (g_tax_info_tbl) before each calculation cycle.
- OFFSET_FACTOR — Applies an offset factor, typically associated with tax recovery or rounding adjustments within the calculation.
- GET_AMOUNT — Retrieves a tax amount from the calculated results for downstream consumption.
Tables Accessed
The package reads and writes an extensive set of APPS synonyms spanning Payables, Purchasing, Receivables, and shared reference data. AP_INVOICES_ALL and AP_INVOICE_DISTRIBUTIONS_ALL supply invoice header and distribution tax lines. AP_SUPPLIER_SITES_ALL, AP_SYSTEM_PARAMETERS, and AP_TAX_CODES_ALL provide supplier site tax attributes, system-level tax defaults, and tax code definitions. AR_TAX_GROUP_CODES_ALL supports tax group resolution. FINANCIALS_SYSTEM_PARAMS_ALL, FND_APPLICATION, FND_CURRENCIES, and GL_TAX_OPTION_ACCOUNTS supply currency, application, and tax accounting references. HR_LOCATIONS_ALL, HZ_LOCATIONS, and MTL_SYSTEM_ITEMS resolve location and item-based tax determination. PO_HEADERS_ALL and PO_DISTRIBUTIONS_ALL support Purchasing-side tax calculation.
Usage Notes
AP_TAX_ENGINE_PKG is invoked internally by Oracle Payables and Oracle Purchasing forms and concurrent programs whenever tax must be derived for a transaction. It is referenced by two other packages, indicating shared internal reuse. Because the package is classified as OTHER rather than a public API, custom code should exercise caution when calling it directly; CALLING_SEQUENCE parameters and global table state (g_tax_info_tbl) must be managed correctly. The 12.1.1 and 12.2.2 implementations rely on native dynamic SQL, so the package remains compatible with the EBS 12.x online patching model. Custom extensions typically wrap CALCULATE_TAX rather than modifying the package body.
-
PACKAGE BODY: APPS.AP_TAX_ENGINE_PKG
12.1.1
-
PACKAGE BODY: APPS.AP_TAX_ENGINE_PKG
12.2.2
-
PACKAGE: APPS.AP_TAX_ENGINE_PKG
12.1.1
-
PACKAGE: APPS.AP_TAX_ENGINE_PKG
12.2.2
-
APPS.AP_TAX_ENGINE_PKG dependencies on AP_TAX_CODES_ALL
12.2.2
-
APPS.AP_TAX_ENGINE_PKG dependencies on AP_TAX_CODES_ALL
12.1.1
-
APPS.AP_TAX_ENGINE_PKG dependencies on AP_INVOICE_DISTRIBUTIONS_ALL
12.2.2
-
APPS.AP_TAX_ENGINE_PKG dependencies on AP_INVOICE_DISTRIBUTIONS_ALL
12.1.1
-
APPS.AP_TAX_ENGINE_PKG dependencies on AP_SUPPLIER_SITES_ALL
12.2.2
-
APPS.AP_TAX_ENGINE_PKG dependencies on AP_SUPPLIER_SITES_ALL
12.1.1
-
APPS.AP_TAX_ENGINE_PKG dependencies on AP_TAX_CODES_ALL
12.2.2
-
APPS.AP_TAX_ENGINE_PKG dependencies on AP_TAX_CODES_ALL
12.1.1
-
APPS.AP_TAX_ENGINE_PKG dependencies on AP_SUPPLIER_SITES_ALL
12.2.2
-
APPS.AP_TAX_ENGINE_PKG dependencies on AP_SUPPLIER_SITES_ALL
12.1.1
-
APPS.AP_TAX_ENGINE_PKG dependencies on AP_TAX_ENGINE_PKG
12.1.1
-
APPS.AP_TAX_ENGINE_PKG dependencies on AP_TAX_ENGINE_PKG
12.2.2
-
APPS.AP_TAX_ENGINE_PKG dependencies on FND_LOG
12.1.1
-
APPS.AP_TAX_ENGINE_PKG dependencies on FND_LOG
12.2.2
-
APPS.AP_TAX_ENGINE_PKG dependencies on AP_INVOICE_DISTRIBUTIONS_ALL
12.2.2
-
APPS.AP_TAX_ENGINE_PKG dependencies on AP_INVOICE_DISTRIBUTIONS_ALL
12.1.1