Search Results local_article_id




Overview

OKC_TERMS_DOC_LATEST_ART_V is a VALID Oracle EBS view owned by the APPS schema within the OKC - Contracts Core product family. It is an Articles ("ART") oriented view that exposes contract terms articles together with their latest version resolution information. The view is designed to present, for each standard contract article attached to a document, the identifying names, labels, version numbers, and adoption attributes required by Contracts Core functionality.

A key characteristic of this view is that it does not simply read columns from base tables. Instead, it is a function-based view that invokes several PL/SQL functions from the OKC_TERMS_UTIL_PVT package to derive descriptive values such as article name, section label, article version number, latest article version number, latest article version ID, local article ID, and adoption type. This design makes the view a convenient reporting and integration surface, because consumers can retrieve pre-derived latest-version facts without replicating the underlying resolution logic themselves.

The view is generally used in the context of Oracle Contracts Core terms and conditions processing, where articles, sections, and their versioning must be resolved against the documents that adopt them. Because the view filters to standard articles (STANDARD_YN = 'Y') and requires a non-null ARTICLE_VERSION_ID, its result set is specifically scoped to the standard, versioned article content relevant to contract terms processing.

Underlying Base Objects

The documented metadata identifies three referenced base objects for this view: OKC_ARTICLES_ALL (SYNONYM), OKC_K_ARTICLES_B (SYNONYM), and the OKC_TERMS_UTIL_PVT package. The view definition joins OKC_K_ARTICLES_B (aliased K) with OKC_ARTICLES_ALL (aliased ART) on the condition that K.SAV_SAE_ID equals ART.ARTICLE_ID, and it restricts the result to rows where ART.STANDARD_YN = 'Y' and K.ARTICLE_VERSION_ID IS NOT NULL.

OKC_K_ARTICLES_B is the article assignment/base entity that links a standard article to a document context, supplying the SAV_SAE_ID, ARTICLE_VERSION_ID, SCN_ID, ID, DOCUMENT_TYPE, DOCUMENT_ID, and OBJECT_VERSION_NUMBER values used throughout the select list. OKC_ARTICLES_ALL provides the article master information, including the STANDARD_YN flag that determines whether the article is standard. The OKC_TERMS_UTIL_PVT package supplies the derivative functions used to compute display and resolution columns. Collectively, these objects establish the view as a join of article assignment data with article master data, enriched by utility function calls.

Key Columns

The view exposes fifteen columns. Several are function-derived descriptive values: ARTICLE_NAME, derived from GET_ARTICLE_NAME using SAV_SAE_ID and ARTICLE_VERSION_ID; SECTION_LABEL, derived from GET_SECTION_LABEL using SCN_ID; ARTICLE_VERSION_NUMBER, derived from GET_ARTICLE_VERSION_NUMBER; and LATEST_ARTICLE_VERSION_NUMBER, derived from GET_LATEST_ART_VERSION_NO using SAV_SAE_ID, DOCUMENT_TYPE, and DOCUMENT_ID.

Resolution-related columns include LATEST_ARTICLE_VERSION_ID, derived from GET_LATEST_ART_VERSION_ID; LOCAL_ARTICLE_ID, derived from GET_LOCAL_ARTICLE_ID; and ADOPTION_TYPE, derived from GET_ADOPTION_TYPE. These columns are central to understanding whether an article version is the latest applicable version within a given document context and how the article is adopted.

  • ARTICLE_ID — sourced from K.SAV_SAE_ID, the standard article identifier.
  • ARTICLE_VERSION_ID and SECTION_ID — the version and section identifiers; SECTION_ID is sourced from K.SCN_ID.
  • OBJECT_TYPE — a constant literal 'ARTICLE' identifying the row type.
  • KARTICLES_ID — sourced from K.ID, the article record identifier. This is the column most commonly associated with the search term "karticles_id", and it provides the surrogate key of the underlying OKC_K_ARTICLES_B row.
  • DOCUMENT_TYPE, DOCUMENT_ID — the document context in which the article is used.
  • OBJECT_VERSION_NUMBER — the optimistic locking version of the underlying article row.

Common Use Cases and Queries

Typical use cases include reporting the latest version of each standard article per contract document, retrieving article names and section labels for display, and determining the adoption type and local article identifier for integration with external or downstream systems. Because KARTICLES_ID is exposed directly, the view is frequently queried by that key when troubleshooting a specific article record or correlating it to the base table.

A common query pattern selects the latest article information for a document:

  • SELECT KARTICLES_ID, ARTICLE_ID, ARTICLE_NAME, SECTION_LABEL, ARTICLE_VERSION_NUMBER, LATEST_ARTICLE_VERSION_NUMBER, LATEST_ARTICLE_VERSION_ID, ADOPTION_TYPE FROM OKC_TERMS_DOC_LATEST_ART_V WHERE DOCUMENT_ID = :p_document_id AND DOCUMENT_TYPE = :p_document_type;
  • SELECT ARTICLE_NAME, LATEST_ARTICLE_VERSION_NUMBER, LOCAL_ARTICLE_ID FROM OKC_TERMS_DOC_LATEST_ART_V WHERE KARTICLES_ID = :p_karticles_id;

Because several columns are computed through OKC_TERMS_UTIL_PVT functions, performance may be affected by the number of rows returned; filtering by DOCUMENT_ID or KARTICLES_ID narrows the result set and allows the function calls to execute over a smaller data volume. Overall, OKC_TERMS_DOC_LATEST_ART_V serves as a focused, latest-version-aware reporting interface over standard contract articles in Oracle Contracts Core.