Results for “g_scope”
50+ results
AI-generated from documented ETRM metadata — verify critical details on the linked pages.
Overview
OKL_COPY_CONTRACT_PUB is the public application programming interface (API) package body for contract duplication within the Oracle Enterprise Trading and Risk Management (ETRM) module of Oracle E-Business Suite. It is owned by the APPS schema and classified as a PUB API, which designates it as the supported, externally callable entry point for the contract copy business process. In Oracle EBS 12.1.1 and 12.2.2, this package enables users and calling programs to create a new lease or service contract by replicating the structure, lines, components, rules, party roles, and articles of a source contract.
The package body contains the implementation logic for the procedures declared in the corresponding specification. It acts as a thin, validated wrapper over the private package OKL_COPY_CONTRACT_PVT, delegating the substantive copy operations while exposing a stable, governed interface. Its status is VALID, confirming that the compiled body is free of errors and that all dependencies resolve successfully.
Key Procedures and Functions
The package exposes 16 documented procedures and functions, of which the following are the principal ones:
- COPY_CONTRACT — the primary entry point that orchestrates the full contract duplication, including header, lines, and associated attributes.
- COPY_LEASE_CONTRACT and COPY_LEASE_CONTRACT_NEW — variants that copy a lease contract, with the newer version reflecting revised copy semantics.
- COPY_CONTRACT_LINES — replicates the line-level detail of the source contract.
- COPY_COMPONENTS — copies the pricing or financial components attached to contract lines.
- COPY_RULES — duplicates the rule sets associated with the source contract.
- COPY_PARTY_ROLES — reproduces the party role assignments on the target contract.
- COPY_ARTICLES and COPY_LATEST_ARTICLES — replicate contract articles, the latter targeting the most recent article versions.
- IS_COPY_ALLOWED and IS_SUBCONTRACT_ALLOWED — validation functions that determine whether a given contract may be copied or subcontracted.
- DERIVE_LINE_STYLE — computes the line style to be applied on the newly created contract lines.
- UPDATE_TARGET_CONTRACT — applies post-copy updates to the target contract record.
Tables Accessed
Per the documented dependency metadata, OKL_COPY_CONTRACT_PUB itself does not directly reference base tables; the underlying table access is performed through OKL_COPY_CONTRACT_PVT and its supporting packages. The package depends on OKL_API and FND_API for standard ETRM and Oracle Application Object Library error-handling and messaging, on OKC_CVM_PVT for contract version management, and on the private copy package for the physical replication of contract data. Together these dependencies read and write the OKL contract header, line, component, rule, party role, and article tables during a copy operation.
Usage Notes
OKL_COPY_CONTRACT_PUB is not referenced by any other database object, confirming its role as a top-level public interface rather than an internal utility. It is typically invoked from ETRM contract forms when a user selects the copy action, and from custom PL/SQL or concurrent programs that automate contract duplication. Callers should invoke the procedures in this package rather than the private package to ensure supported, upgrade-safe behavior. Validation functions such as IS_COPY_ALLOWED should be called before initiating a copy to confirm business eligibility.