Search Results error_tbl_type




Overview

The APPS.OKL_CURE_CALC_PVT package is a private (PVT) PL/SQL API belonging to the Oracle E-Business Suite Lease Management (OKL) module, part of the Enterprise Territory and Revenue Management (ETRM) family of applications. Its principal business function is to support the Lease Management cure and repurchase process. In the context of lease and vendor program administration, "cure" refers to the remediation of delinquent contracts, whereby a vendor program participant is permitted to bring a defaulted or delinquent contract back into good standing by paying a calculated cure amount, or alternatively to repurchase the underlying asset. The package identifies delinquent contracts and, applying vendor program rules, calculates the associated Cure and Repurchase Amounts.

Critically, the calculation of cure and repurchase amounts is permitted only for those contracts whose associated Vendor Programs explicitly allow cures and repurchases. The package header notes that it is designed to operate as a concurrent process, meaning it is intended to be run as a batch job that evaluates contracts in bulk rather than through interactive, single-record user actions. The package is declared AUTHID CURRENT_USER, so it executes with the privileges of the invoking user, and it is owned by the APPS schema. It is referenced by one other package within the application, indicating it is a lower-level utility consumed by higher-level program logic.

Key Procedures and Functions

The documented package exposes two procedures:

  • GENERATE_CURE_AMOUNT — This is the core public procedure of the package. It drives the concurrent process that identifies delinquent contracts and calculates the cure and repurchase amounts based on the applicable vendor program rules. It accepts a contract number as input and returns status information through standard concurrent program output parameters (an error buffer and a return code). Its purpose is to produce the cure amount records consumed downstream by the lease management delinquency workflow.
  • WRITE_LOG — A diagnostic logging procedure used to record messages at a specified message level. It supports the package's internal error and success tracking, which is organized through PL/SQL record and index-by tables (error_rec_type, error_tbl_type, and error_message_type) that capture contract number, cure type, and cure amount for both error and success rows.

The package also declares package-level constants for the package name and application short name, and derives a logging threshold from the FND_AS_MSG_LEVEL_THRESHOLD profile option.

Tables Accessed

The package reads and writes a range of Lease Management and Receivables tables through APPS synonyms:

  • OKC_K_HEADERS_B — the contract header entity, providing contract number and contract identity for delinquency evaluation.
  • OKL_CURE_AMOUNTS — the target table where calculated cure type and cure amount values are recorded.
  • AR_PAYMENT_SCHEDULES and AR_RECEIVABLE_APPLICATIONS — Receivables tables used to assess payment status and delinquency, which underpins the identification of contracts requiring cure.
  • OKC_RULES_B and OKC_RULE_GROUPS_B — rule and rule group definitions that encode vendor program terms governing whether cures and repurchases are permitted and how amounts are computed.
  • OKL_K_HEADERS, OKL_STRM_TYPE_TL, OKL_TRX_QUOTES_B, and OKL_TXD_AR_LN_DTLS_B — Lease Management header, stream type, transaction quote, and transaction detail tables supporting amount derivation.
  • DUAL and PLITBLM — utility objects used for expression evaluation and PL/SQL table operations.

Usage Notes

This package is a private API and is not intended for direct invocation by end users or external customizations; Oracle supports only documented public APIs, and PVT packages are internal implementation objects subject to change. In practice, OKL_CURE_CALC_PVT.GENERATE_CURE_AMOUNT is invoked by the Lease Management concurrent program that generates cure amounts for delinquent contracts, consistent with the header comment describing it as a concurrent process. It may also be called programmatically by the higher-level package that references it. Administrators typically schedule or submit this process from the EBS concurrent manager or an associated Lease Management form, supplying a contract number to scope the calculation. Because the package relies on profile option values such as FND_AS_MSG_LEVEL_THRESHOLD for logging verbosity, output diagnostics are controlled through standard profile configuration. Custom code should avoid calling this package directly and should instead use the supported public Lease Management APIs.