Search Results ap_invoice_distributions_s




Overview

APPS.AP_AID_TABLE_HANDLER_PKG is a PL/SQL package body in the Oracle E-Business Suite Payables (AP) module. Its name reflects its role as a table handler for the AP_INVOICE_DISTRIBUTIONS entity — specifically the AID (AP Invoice Distributions) naming convention used throughout the AP schema. The package encapsulates row-level Data Manipulation Language (DML) operations against invoice distribution data, providing a controlled interface for inserting, updating, and deleting records in the underlying distribution tables rather than allowing direct manipulation by calling code.

In the context of Oracle EBS 12.1.1 and 12.2.2, the AP_INVOICE_DISTRIBUTIONS table stores the accounting distributions generated from invoice lines. Each distribution represents a portion of an invoice line charged to a particular accounting code combination, along with associated amounts, tax information, and matching references. The companion table AP_INVOICE_DISTRIBUTIONS_S is the shadow (audit) table maintained by Oracle's Audit Trail or journaling infrastructure, typically populated by database triggers or the DBI (database interface) layer when changes occur to the primary distributions table.

This package is classified as an "OTHER" API rather than a public, documented open interface. It is an internal technical utility rather than a supported integration point, and Oracle does not publish a formal parameter specification for it.

Key Procedures and Functions

The package body exposes three documented procedures, all conforming to the standard table-handler pattern used across many Oracle EBS internal packages:

  • INSERT_ROW — Inserts a new row into the invoice distributions structure. It handles the creation of a distribution record, including any necessary interaction with the shadow table and the DBI notification layer (AP_DBI_PKG) so that dependent business events are signalled.
  • UPDATE_ROW — Modifies an existing distribution row. This is the procedure invoked when distribution amounts, accounting flexfields, or matching attributes change, and it ensures the audit companion table is kept in synchronization.
  • DELETE_ROW — Removes a distribution record. Because distributions participate in accounting and audit trails, deletion is routed through this handler to preserve referential integrity and audit consistency.

No parameter lists are documented in the ETRM metadata, and none should be assumed; callers must obtain signature details from the actual package specification in the instance.

Tables Accessed

Two tables are referenced through APPS synonyms:

  • AP_INVOICE_DISTRIBUTIONS — The primary transaction table. The handler reads and writes here to persist distribution rows. This is the table most directly associated with the user's search term.
  • AP_INVOICE_DISTRIBUTIONS_S — The shadow/audit counterpart. The handler maintains this in parallel to support audit trail and change-tracking requirements.

The package also depends on AP_DBI_PKG, indicating it raises business events through the DBI framework when distribution data changes, and on APP_EXCEPTION and FND_MESSAGE for standardized error handling and message retrieval. These dependencies confirm the package is integrated into the broader AP event and error-handling infrastructure rather than operating in isolation.

Usage Notes

AP_AID_TABLE_HANDLER_PKG is an internal implementation package. The ETRM metadata states it is not referenced by any other database object and is itself referenced by only one other package, suggesting limited, tightly scoped usage. It is not intended for direct invocation by customer extension code, concurrent programs, or Oracle Forms outside the module's own internal logic. The documented reliance on AP_DBI_PKG implies it may be called during invoice processing flows where distribution events must propagate to downstream subscribers. Because the procedures lack published signatures and the package is classified as an unsupported internal API, customizations should avoid calling it directly; instead, developers should use supported AP APIs such as AP_INVOICE_DISTRIBUTIONS_PKG or the Payables open interfaces where distribution creation or maintenance is required.