Search Results validate_delete_document
Overview
PO_HEADERS_SV1 is a server-side (SV) PL/SQL package body owned by APPS in the Oracle E-Business Suite Purchasing module. It provides the low-level validation and persistence services that support deletion and status-change operations on purchasing documents, primarily purchase orders and releases stored in the PO_HEADERS / PO_HEADERS_ALL schema. The package is classified under the "OTHER" API category in the ETRM repository, indicating that it is an internal implementation package rather than a formally supported public API. Its principal responsibility is to determine whether a given document may be deleted, and to carry out the deletion while maintaining referential integrity across the surrounding Purchasing and Subledger Accounting tables.
The package header comment ($Header: POXPOH1B.pls 120.4 2007/12/04) shows that the source file has been stable since release 12.0 and is carried forward unchanged into 12.1.1 and 12.2.2. Nine documented program units are recorded, with the deletion-related entry points being the ones most commonly reached from the Purchasing forms and from other PO packages.
Key Procedures and Functions
- VALIDATE_DELETE_DOCUMENT — The entry point referenced by the search term validate_delete_document. It inspects a purchasing document to determine whether deletion is permissible, returning an outcome that the caller uses to either proceed with deletion or block it and raise a user-facing error. The validation logic is expected to consider document type, approval and workflow state, distribution and release activity, and the presence of downstream accounting events.
- DELETE_DOCUMENT — Performs the physical (or logical) removal of the document header and its dependent entities once validation has succeeded. It is the counterpart routine to VALIDATE_DELETE_DOCUMENT and is normally invoked only after that validation returns a favorable result.
- lock_row_for_status_update — A locking helper that selects the target row from PO_HEADERS with
FOR UPDATE ... NOWAIT. Failing to acquire the lock raises FORM_RECORD_DELETED, and lock contention is translated into the PO_ALL_CANNOT_RESERVE_RECORD message. Other errors are routed through PO_MESSAGE_S.SQL_ERROR with a progress marker. - Additional units (NAME and others) — The metadata records nine program units in total, including a NAME routine used for object identification. Several historical functions such as val_po_encumbered and get_doc_num remain in the file as commented-out stubs, confirming they are no longer active.
Tables Accessed
The package touches a broad set of Purchasing and accounting tables through APPS synonyms, reflecting the dependency graph that must be resolved before a document can safely be removed.
- PO_HEADERS / PO_HEADERS_ALL — the document header, both for row locking and for deletion.
- PO_LINES_ALL, PO_DISTRIBUTIONS / PO_DISTRIBUTIONS_ALL, PO_BC_DISTRIBUTIONS — line and distribution detail that must be validated and cleared.
- PO_RELEASES / PO_RELEASES_ALL — blanket and planned release records subordinate to the header.
- PO_ACTION_HISTORY, PO_DOCUMENT_TYPES, PO_EXHIBIT_DETAILS — action audit, document type control, and exhibit attachments.
- PO_REQUISITION_HEADERS_ALL — referenced to establish the sourcing relationship for the document.
- XLA_EVENTS — Subledger Accounting events, checked to prevent deletion of documents that have already generated accounting entries.
Usage Notes
PO_HEADERS_SV1 is a private implementation package. It is referenced by five other packages in the ETRM repository and is invoked indirectly, typically from the Purchasing forms when a user attempts to delete a document, and from server-side packages that orchestrate document maintenance. Because it is not a supported public API, direct calls from custom code are not recommended; the supported interfaces should be preferred. Customers upgrading from 12.1.1 to 12.2.2 can rely on the fact that the file header and program structure are unchanged between these releases, so behavior of validate_delete_document and delete_document remains consistent.
-
APPS.PO_HEADERS_SV1 SQL Statements
12.1.1
-
APPS.PO_HEADERS_SV1 SQL Statements
12.2.2
-
PACKAGE BODY: APPS.PO_HEADERS_SV1
12.1.1
-
PACKAGE BODY: APPS.PO_HEADERS_SV1
12.2.2
-
PACKAGE: APPS.PO_HEADERS_SV1
12.1.1
-
PACKAGE: APPS.PO_HEADERS_SV1
12.2.2
-
APPS.PO_HEADERS_SV1 dependencies on PO_HEADERS_SV1
12.2.2
-
APPS.PO_DOCUMENT_UPDATE_PVT dependencies on PO_HEADERS_SV1
12.1.1
-
APPS.PO_DOCUMENT_UPDATE_PVT dependencies on PO_HEADERS_SV1
12.2.2
-
APPS.PO_HEADERS_SV1 dependencies on PO_HEADERS_SV1
12.1.1
-
APPS.PO_HEADERS_SV1 dependencies on PO_HEADERS
12.1.1
-
APPS.PO_HEADERS_SV1 dependencies on PO_HEADERS
12.2.2
-
APPS.PO_HEADERS_SV1 dependencies on PO_LOG
12.1.1
-
APPS.PO_HEADERS_SV1 dependencies on PO_LOG
12.2.2
-
APPS.PO_DOCUMENT_UPDATE_PVT SQL Statements
12.1.1
-
APPS.PO_DOCUMENT_UPDATE_PVT SQL Statements
12.2.2
-
APPS.PO_DOCUMENT_UPDATE_PVT dependencies on PO_HEADERS
12.2.2
-
APPS.PO_DOCUMENT_UPDATE_PVT dependencies on PO_HEADERS
12.1.1
-
APPS.PO_DOCUMENT_UPDATE_PVT dependencies on PO_CORE_S
12.2.2
-
APPS.PO_DOCUMENT_UPDATE_PVT dependencies on PO_CORE_S
12.1.1
-
PACKAGE BODY: APPS.PO_DOCUMENT_UPDATE_PVT
12.2.2
-
PACKAGE BODY: APPS.PO_DOCUMENT_UPDATE_PVT
12.1.1