Search Results force_delete_row




Overview

OKC_CLE_PVT is a private PL/SQL package owned by the APPS schema in Oracle E-Business Oracle Contracts (OKC) module. It is the low-level data access and persistence layer for contract line entities — specifically the "CLE" structures represented by the cle_rec_type record declared in the package specification. The package operates with AUTHID CURRENT_USER, meaning it executes under the privileges of the calling schema rather than as its definer, which is characteristic of Oracle's private (PVT) API layer used behind the public OKC_API wrapper.

The cle_rec_type record exposes the full attribute set of a contract line, including identifiers (id, chr_id, cle_id, cle_id_renewed, dnz_chr_id), status and transaction codes, pricing attributes (price_unit, price_negotiated, price_unit_percent, price_level_ind, price_type, currency_code), invoice and DPAS flags, and standard WHO columns. Defaulting each field to OKC_API.G_MISS_* allows the DML routines to distinguish intentionally supplied values from absent ones — a standard Oracle APIs pattern. The package is referenced by approximately fifty other packages, indicating it is a foundational component of the Contracts line-processing stack.

Key Procedures and Functions

ETRM documents eighteen procedures and functions. The core CRUD set comprises INSERT_ROW, UPDATE_ROW, DELETE_ROW, LOCK_ROW, and VALIDATE_ROW, which together provide insert, update, delete, concurrency locking, and business-rule validation for contract line records. FORCE_DELETE_ROW — the routine associated with the user's search term — performs an unconditional delete that bypasses the normal validation and referential safeguards applied by DELETE_ROW; it is typically reserved for administrative or cleanup scenarios such as removing orphaned or test data.

Version-management routines include CREATE_VERSION, RESTORE_VERSION, CHANGE_VERSION, and API_COPY, supporting the Contracts versioning model in which contract lines are snapshotted and restored across revisions. QC provides a quick-check or row-status query capability. ADD_LANGUAGE and INSERT_ROW_UPG handle translated (TL) records and upgrade-path inserts respectively. Several of these routines operate in both a business-facing and an upgrade context, which accounts for the parallel presence of INSERT_ROW and INSERT_ROW_UPG.

Tables Accessed

The package maintains the base and history tables for contract lines: OKC_K_LINES_B (base columns, statuses, and the source of the cle_rec_type datatypes), OKC_K_LINES_TL and OKC_K_LINES_TLH (translated and history translation rows), and OKC_K_LINES_BH (base history). OKC_K_HEADERS_ALL_B supplies the parent contract header context. Reference and validation lookups are drawn from OKC_CLASS_OPERATIONS, OKC_OPERATION_INSTANCES, OKC_OPERATION_LINES, and OKC_STATUSES_B. Pricing information is validated against QP_LIST_HEADERS_B and QP_LIST_LINES, while FND_LANGUAGES, DUAL, and PLITBLM (the PL/SQL integer table type) support language handling, scalar evaluation, and bulk processing respectively.

Usage Notes

Because OKC_CLE_PVT is classified as a private API, it is not intended for direct invocation by end users or external integrations. Calls originate from the public OKC_API layer, from other OKC packages (fifty documented referrers), from the Contract Lines and Contract Headers forms, and from concurrent programs that process contract line data — for example renewal, versioning, or mass-update programs. Custom code should invoke OKC_API rather than OKC_CLE_PVT directly, because the private layer omits caller-facing validation and message handling. Where FORCE_DELETE_ROW is required, its use should be limited to corrective maintenance scripts executed with DBA oversight, since it circumvents the integrity checks enforced by DELETE_ROW.