Search Results g_view




Overview

OKC_KEXP_PVT is a private PL/SQL package in the Oracle Contracts (OKC) module of Oracle E-Business Suite, owned by the APPS schema. Its designation as a "PVT" (private) API indicates that it is an internal implementation unit, not a published interface for external or customer-facing integration. The package supports the Contracts Expert reporting facility, which presents contract search and reporting data through the OKC_KEXP_REPORT view and its associated table structure. The package header carries a header revision string dated 2005, reflecting its origin in the earlier Contracts Foundation development lineage; it remains present and documented in ETRM 12.2.2, confirming continued availability through the 12.1.1 and 12.2.2 releases.

Functionally, OKC_KEXP_PVT manages the population and maintenance of Contract Expert report rows and supplies helper logic used when those rows are rendered, including resolution of sales representative names. It is tightly scoped: the header exposes only two procedures and one function, all oriented around the OKC_KEXP_REPORT staging structure.

Key Procedures and Functions

  • LOAD_KSRCH_ROWS — Populates the OKC_KEXP_REPORT staging table with rows derived from a contract search. It accepts a search where-clause to filter the contract population and returns both a standard return status and an identifier for the generated report. This is the principal data-generation entry point.
  • DELETE_KSRCH_ROWS — Removes previously generated report rows, optionally bounded by a from-date and to-date range so that only report data within a specified period is purged. It returns a return status to indicate success or failure.
  • GET_SALESREP_NAME — A VARCHAR2 function that resolves and returns a sales representative name. It is invoked with two identifier parameters, p_id1 and p_id2, which supply the key values needed to derive the representative's display name during report rendering. This is the object most frequently sought by developers searching for "get_salesrep_name".

Tables Accessed

  • OKC_KEXP_REPORT — The primary staging table for Contract Expert report output. LOAD_KSRCH_ROWS inserts rows into it and DELETE_KSRCH_ROWS removes them.
  • OKC_KEXP_REPORT_S1 — A sequence or supplemental structure associated with the report table, supporting row key generation or ordering during load and delete operations.
  • DUAL — Used for single-row expression evaluation, typical of PL/SQL helper functions such as GET_SALESREP_NAME.
  • PLITBLM — An Oracle Applications internal table type (a PL/SQL index-by table of VARCHAR2) referenced in package logic, commonly for handling lists or name-value collections rather than as a physical business table.

Usage Notes

Because OKC_KEXP_PVT is a private package, it is not intended for direct invocation from customer extensions. It is called by the Contracts Expert reporting flow — typically from the Contracts workbench or a report-generation program that first clears prior output via DELETE_KSRCH_ROWS, then loads fresh rows via LOAD_KSRCH_ROWS, and finally renders the report's content using helper functions such as GET_SALESREP_NAME. The ETRM metadata notes that the package is referenced by one other package, indicating a single internal caller rather than broad reuse.

Searches for "get_salesrep_name" generally originate from developers tracing how a sales representative name appears on a contract report or attempting to reuse the lookup logic. Since the package is private and marked Oracle proprietary/confidential, custom code should not call it directly; the supported approach is to query the underlying sales representative data through documented public Contracts APIs or the OKC_KEXP_REPORT view instead.