Search Results get_line_change




Overview

PO_DOCUMENT_UPDATE_PVT is a private PL/SQL package in the APPS schema that provides the core engine for applying changes to existing Oracle Purchasing documents. Operating in Oracle E-Business Suite 12.1.1 and 12.2.2, it is the implementation layer behind the public change management APIs, notably PO_CHANGE_API1_S. The package accepts a change record (PO_CHANGES_REC_TYPE) and an error record (PO_API_ERRORS_REC_TYPE), validates the requested modification against the document's current state, and persists the resulting line, shipment, and distribution changes to the transactional tables.

The "PVT" classification indicates that the package is not intended as a published integration interface. External and internal callers are expected to invoke the public wrapper APIs, which delegate to this package for the actual update logic. The package is registered as VALID in the ETRM dictionary and is a dependency of several higher-level change and integration packages.

Key Procedures and Functions

Tables Accessed

The package reads and writes the primary Purchasing document tables through APPS synonyms: PO_LINES, PO_LINE_LOCATIONS, and PO_DISTRIBUTIONS, which hold the line, shipment, and distribution records being modified. PO_DOCUMENT_TYPES_ALL_B supplies document type attributes that govern allowable actions. Supporting reference data includes FINANCIALS_SYSTEM_PARAMETERS, FND_CURRENCIES, HR_LOCATIONS_ALL, the HZ customer and party site tables (HZ_CUST_ACCT_RELATE_ALL, HZ_CUST_ACCT_SITES_ALL, HZ_CUST_SITE_USES_ALL, HZ_LOCATIONS, HZ_PARTY_SITES), and item master tables MTL_SYSTEM_ITEMS, MTL_SYSTEM_ITEMS_B, and MTL_GRADES. These are used for validation defaulting and for resolving values required when changes affect sourcing, pricing, or destination information.

Usage Notes

The package is invoked indirectly. Documented callers include PO_CHANGE_API1_S, PO_DOCUMENT_UPDATE_GRP, PO_OM_INTEGRATION_GRP, PO_RESCHEDULE_PKG, and PO_WIP_INTEGRATION_GRP, each of which calls into PO_DOCUMENT_UPDATE_PVT for the underlying update logic. In practice it is therefore executed when a user modifies a purchase order through the Purchasing forms, when an order-management or WIP integration reschedules or adjusts supply, and when a concurrent program performs scheduled or mass document maintenance. Direct invocation from custom code is not recommended; customizations should call the public PO_CHANGE_API1_S or the appropriate group package so that validation, error handling, and workflow launching are applied consistently.