Search Results okl_split_contract_pub




Overview

The OKL_SPLIT_CONTRACT_PUB package body is the public API layer within the Oracle Lease Management (OKL) module of Oracle E-Business Suite, classified as a PUB API for external or cross-module consumption. It exposes the business logic required to split a single lease or contract into two or more distinct contracts while preserving the integrity of the underlying financial, accounting, and line-level structures. This functionality supports scenarios such as partial asset returns, portfolio restructuring, lease renegotiation, and mid-term modifications in which one contract must be divided into logically independent instruments. The package follows the standard Oracle EBS PL/SQL API architecture: a thin public wrapper (OKL_SPLIT_CONTRACT_PUB) that delegates transactional work to a private implementation package (OKL_SPLIT_CONTRACT_PVT), performing API compatibility checks, initializing the FND message stack, and routing return-status and message data back to the caller.

Key Procedures and Functions

  • CREATE_SPLIT_CONTRACT – The main processing entry point. It accepts an existing contract number and a set of new top-line structures, invokes the private split logic, and returns a newly constructed contract line collection. The routine enforces API version compatibility through FND_API.Compatible_API_Call and honors the p_init_msg_list flag to conditionally initialize the message stack.
  • POST_SPLIT_CONTRACT – Drives the accounting and downstream posting of the split results, ensuring the resulting contracts are booked and their transactional records properly generated.
  • CANCEL_SPLIT_PROCESS – Provides a rollback or reversal capability, allowing a split operation that has been initiated or partially completed to be cancelled and the contract state restored.
  • CHECK_SPLIT_PROCESS – A validation routine that verifies whether a given contract is eligible for splitting, returning status information to the caller before the more expensive create operation is attempted.
  • SET_CONTEXT – Establishes the application and organizational context required by the OKL APIs, ensuring that multi-organization and security-group settings are correct prior to processing.

Tables Accessed

The package operates against two primary base tables accessed through APPS synonyms:

  • OKC_K_HEADERS_B – The core contract header table shared with Oracle Contracts. The split process reads the source contract header and creates or updates header records for the resulting contracts, maintaining the contract number, status, and versioning relationships.
  • OKL_TRX_CONTRACTS – The lease transaction contract table that stores OKL-specific contract attributes. Split processing writes the transaction-level linkage that ties each new contract to its transactional counterpart, preserving financial and accounting references.

Usage Notes

Invocation of OKL_SPLIT_CONTRACT_PUB typically originates from the Oracle Lease Management contract forms, where an end user performs a split action, or from concurrent programs that automate bulk contract restructuring. Custom code and integrations should call only the _PUB procedures, never the private _PVT layer, and must pass a valid p_api_version to satisfy the compatibility check. Callers should initialize the message list where appropriate and always inspect x_return_status, x_msg_count, and x_msg_data before proceeding. Because the package alters contract headers and transactional records, split operations should be wrapped in a controlled transaction with savepoints to permit rollback via the CANCEL_SPLIT_PROCESS routine on error. Version identifiers in the header ($Header: OKLPSKHB.pls 115.7) confirm the package has been maintained across releases and is compatible with both 12.1.1 and 12.2.2 schemas.