Search Results g_one_doi




Overview

OKL_FORMULAFUNCTION_PVT is a private PL/SQL package in the Oracle E-Business Suite Applications (APPS) schema that supports the Oracle Lease and Finance Management (OKL) module, part of the Enterprise Contracts / ETRM family of products. The package is declared with AUTHID CURRENT_USER, meaning its SQL statements execute with the privileges of the invoking user rather than the package owner, a common convention for internal helper packages in EBS. The _PVT suffix indicates that this is a private package: it is not exposed as a public API and is intended to be called only by other packages within the OKL/OKC product family, primarily the corresponding public API wrapper.

The business purpose of the package is to evaluate the formula-driven financial values associated with lease and finance contracts. Lease contracts in OKL frequently use pricing formulas, and derived monetary amounts such as tax components, bonus amounts, and revenue amounts must be computed consistently at the point of contract entry, re-pricing, or calculation. OKL_FORMULAFUNCTION_PVT encapsulates that calculation logic so that the same deterministic rules are applied regardless of the calling context.

Key Procedures and Functions

The documented ETRM metadata records three program units, all functions:

  • GET_TAX_VALUE — Returns the tax value computed for a contract line or pricing stream according to the applicable formula. It is invoked when the caller requires the tax portion of a calculated amount without recalculating the entire pricing structure.
  • GET_BONUS_VALUE — Returns the bonus value associated with the lease or finance contract element being evaluated. Bonus amounts are typically used in promotional or incentive-driven lease pricing arrangements, so this function isolates the bonus derivation from other components.
  • GET_REVENUE_VALUE — Returns the revenue value attributable to the contract or line under evaluation. This is used where revenue recognition or revenue presentation requires a formula-derived figure rather than a stored column value.

Each function operates on the formula framework shared with the OKC (Oracle Contracts) core API. The package header defines the standard message constants inherited from OKC_API, including G_FORM_RECORD_CHANGED, G_RECORD_LOGICALLY_DELETED, G_REQUIRED_VALUE, G_INVALID_VALUE, and the token constants (G_COL_NAME_TOKEN, G_PARENT_TABLE_TOKEN, G_CHILD_TABLE_TOKEN), plus a custom exception G_EXCEPTION_HALT_VALIDATION. These constants are used to raise standard, translatable error messages when a formula cannot be resolved or a value cannot be derived. The constant G_ONE_DOI reflects the OKC rule that only one "date of interest" is permitted in a given operation.

Tables Accessed

The ETRM metadata for this object does not enumerate specific tables accessed via APPS synonyms, and the referenced-by count is zero for other packages. In practice, the package reads the OKL contract and pricing tables (such as the lease line, pricing, and formula definition tables) that hold the inputs to the formula evaluation, and it inherits the OKC API framework tables used by the common contract infrastructure. Because it is a private helper, it does not own tables or perform DDL; its access is read-oriented, supplying computed values back to its caller.

Usage Notes

OKL_FORMULAFUNCTION_PVT is normally invoked indirectly. The public OKL formula function API calls into this private package to obtain tax, bonus, and revenue figures during contract authoring, re-pricing, and calculation cycles triggered from the Lease and Finance Management forms and from concurrent calculation programs. It is not intended to be called directly by custom code. When the user's search term "change_version" appears in the context of this package, it relates to the OKC/OKL optimistic-locking convention: if a record has been modified by another session, the caller raises G_FORM_RECORD_CHANGED, signalling that the in-memory version is stale and the form must re-query before re-evaluating the formula. Custom integrations should therefore always use the public OKL formula API rather than this private package, and should handle the standard OKC error tokens returned by it.