Search Results okl_ptv_pvt




Overview

OKL_PTV_PVT is a private (PVT-classified) PL/SQL package body in the APPS schema that supports the Oracle E-Business Suite Lease Management (formerly Oracle Lease and Finance Management, OKL/ETRM) product line. It serves as the internal implementation layer for the OKL_PTV business entity, which manages "PTV" (Party/Value) records associated with lease contracts and their related transaction structures. As a "-_PVT" suffix package, it is intended strictly for internal consumption by other ETRM APIs and concurrent programs rather than as a public integration entry point. The package is documented as VALID in the 12.1.1 and 12.2.2 ETRM repositories and is referenced by 10 other database objects in the ETRM schema, indicating a shared utility role for maintaining versioned PTV rows.

Key Procedures and Functions

The package exposes 13 documented procedures and functions, of which the following are explicitly named in the ETRM metadata:

  • QC – A standard ETRM "quality check" or wrapper routine typically used to enforce validation rules before a DML operation executes.
  • CHANGE_VERSION – Manages version transitions for a PTV row, supporting the versioning model used across OKL entities.
  • API_COPY – Copies a PTV record (or set of records) from a source key to a target key, often used during contract copy or amendment flows.
  • INSERT_ROW – Inserts a new PTV row into the underlying table, applying defaulting and shadow-column population.
  • LOCK_ROW – Acquires a row-level lock, typically via SELECT FOR UPDATE, to prevent concurrent modification of a PTV record.
  • UPDATE_ROW – Updates an existing PTV row, including audit and WHO columns.
  • DELETE_ROW – Logically or physically removes a PTV row, subject to referential and business-rule checks.
  • VALIDATE_ROW – Executes the full validation ruleset for a PTV row prior to commit, returning errors via the FND_API/FND_MSG framework.

The remaining five routines in the package body are helper or utility procedures invoked internally by the above.

Tables Accessed

The package body references the following underlying objects through APPS synonyms:

  • OKL_PTQ_VALUES – The base PTV value table. INSERT_ROW, UPDATE_ROW, DELETE_ROW, and LOCK_ROW operate directly against this table, while VALIDATE_ROW and QC consult it to enforce uniqueness and business constraints.
  • OKL_PTL_QUALITYS_V and OKL_PTQ_VALUES_V – Views over the PTV value data, queried for validation lookups and quality checks.
  • PLITBLM – The standard Oracle PL/SQL table-of-varchar2 index-by-binary_integer type used for in-memory collections passed to and from API routines.

Additional dependencies include the OKC_API, OKC_P_UTIL, and OKC_UTIL packages for contract-side validation, FND_API and FND_GLOBAL for the EBS API error-handling and session-context conventions, APP_EXCEPTIONS for exception registration, and OKL_ACCOUNTING_UTIL where PTV data feeds accounting or generates accounting events.

Usage Notes

Because OKL_PTV_PVT is a private package, it is not called directly from Oracle Forms or from customer extensions. It is invoked by the parent OKL_PTV (public API) package, by other OKL_*_PVT packages, and by concurrent programs and workflow activities internal to Lease Management. The CHANGE_VERSION, API_COPY, and LOCK_ROW routines are typically exercised during contract amendment, contract copy, and concurrent reprocessing of PTV records. Custom development should never call OKL_PTV_PVT directly; instead, integrations must use the corresponding public OKL API. The documented dependency set confirms that the package relies on standard EBS API plumbing (FND_API, FND_GLOBAL) and OKC contract utilities, which must be present and valid for the package to compile and execute in 12.1.1 or 12.2.2 environments.