Search Results match_invoice_line




Overview

APPS.AP_MATCHING_UTILS_PKG is a shared PL/SQL utility package within the Oracle E-Business Suite Payables (AP) module. Its primary business function is to supply the low-level computational and data-retrieval logic required to support invoice-to-purchase-order and invoice-to-receipt matching. Invoice matching is the process by which Payables validates that supplier invoices correspond to goods received and purchase order commitments before payment is authorized. Rather than performing matching itself, AP_MATCHING_UTILS_PKG provides the helper routines that the higher-level matching engine (AP_MATCHING_PKG) and validation processes call to determine quantities, prices, amounts, and correction tolerances on receipts, distributions, and invoice lines. The package is classified as OTHER in the ETRM metadata, indicating it is not an externally-facing public API but an internal utility library. It resides in the APPS schema, is VALID, and exposes twenty-seven documented procedures and functions.

Key Procedures and Functions

The documented subprograms fall into several functional groupings:

Tables Accessed

The package operates against the core Payables and related transactional tables through APPS synonyms. Invoice and line data are read from AP_INVOICES, AP_INVOICES_ALL, AP_INVOICE_LINES, and AP_INVOICE_LINES_ALL, with distribution-level detail held in AP_INVOICE_DISTRIBUTIONS and AP_INVOICE_DISTRIBUTIONS_ALL. Supplier and site context is obtained from AP_SUPPLIERS and AP_SUPPLIER_SITES_ALL. Payment and term reference data draws on AP_INVOICE_PAYMENTS and AP_TERMS. System-wide behavior is governed by AP_SYSTEM_PARAMETERS, while AP_ALLOCATION_RULE_LINES supports allocation logic. Currency, territory, and message lookups use FND_CURRENCIES, FND_TERRITORIES_TL, and FND_NEW_MESSAGES respectively. These tables supply the quantities, amounts, and configuration settings required for matching computations and correction tolerance checks.

Usage Notes

AP_MATCHING_UTILS_PKG is an internal dependency rather than a directly invoked public API. The ETRM metadata shows it is referenced by sixteen other packages, including AP_MATCHING_PKG, AP_APPROVAL_PKG, AP_INVOICE_LINES_PKG, AP_PO_AMT_MATCH_PKG, AP_RCT_AMT_MATCH_PKG, AP_RECT_MATCH_PKG, AP_PREPAY_PKG, AP_RETAINAGE_RELEASE_PKG, AP_RECURRING_INVOICES_PKG, and AP_IMPORT_UTILITIES_PKG, as well as the views AP_INVOICE_LINES_V, AP_VIEW_PREPAYS_V, and AP_VIEW_PREPAYS_FR_PREPAY_V. In practice it is exercised whenever invoices are entered, matched, approved, or imported through the Payables forms and concurrent programs, since those processes delegate the underlying matching calculations to it. Customizations should generally avoid calling this package directly, as its interface is not guaranteed for external use; instead, extensions should invoke the documented matching APIs that wrapper this utility. Its own dependencies are limited to SYS.STANDARD, confirming it is a foundational helper layer within the AP stack.