Search Results okc_article_variables_pk1




Overview

The OKC_ARTICLE_VARIABLES table is a core data object within the OKC – Contracts Core module of Oracle E-Business Suite. It stores the individual variables associated with a specific clause (article) version. In Oracle Contracts, clause text frequently contains embedded variables — placeholders or tokens such as contract terms, business values, or reference fields — that are resolved or substituted when a contract document is generated. The rows in OKC_ARTICLE_VARIABLES are not entered manually; they are created by the system, which extracts the embedded variables directly from the clause text during processing. This makes the table an extraction artifact that captures the linkage between a clause version and the business variables referenced within it.

Based on the heuristic Data Vault classification mined from the foreign key structure, this object is best modeled as a link. It resolves a many-to-many relationship between clause versions (OKC_ARTICLE_VERSIONS) and business variables (OKC_BUS_VARIABLES_B), which is characteristic of a link entity connecting two hubs. The two unique indexes reinforce this interpretation, since the same variable code can appear across many article versions and a single article version can reference many variable codes.

Key Information Stored

The documented physical schema for release 12.2.2 contains eight columns. The most significant are described below.

  • ARTICLE_VERSION_ID — Foreign key to OKC_ARTICLE_VERSIONS. Identifies the specific clause version whose text contained the extracted variable. This is the anchor to the contract clause context.
  • VARIABLE_CODE — Foreign key to OKC_BUS_VARIABLES_B. Identifies the business variable that was embedded in the clause text. Together with ARTICLE_VERSION_ID, it forms the business-key candidate.
  • OBJECT_VERSION_NUMBER — The standard Oracle EBS optimistic locking column used to detect concurrent updates.
  • CREATED_BY, CREATION_DATE — Audit columns recording the user and timestamp of row creation. Because rows are system-generated during variable extraction, these values reflect the extraction process.
  • LAST_UPDATE_DATE, LAST_UPDATED_BY, LAST_UPDATE_LOGIN — Audit columns capturing the most recent modification, the user who performed it, and the login session under which it occurred.

The documented primary key is OKC_ARTICLE_VARIABLES_PK1, defined on (VARIABLE_CODE, ARTICLE_VERSION_ID). Two unique indexes are also documented: OKC_ARTICLE_VARIABLES_U1 on (ARTICLE_VERSION_ID, VARIABLE_CODE) and OKC_ARTICLE_VARIABLES_U2 on (VARIABLE_CODE, ARTICLE_VERSION_ID). Both indexes enforce the same uniqueness constraint in opposite column order, meaning the combination of an article version and a variable code may appear only once. This effectively guarantees that a given variable is extracted only once per clause version, even though the identical variable code may be reused across many clause versions.

Common Use Cases and Queries

Typical usage centers on documenting which variables a contract clause depends on. A frequent query pattern retrieves all variables for a clause version:

SELECT v.VARIABLE_CODE, v.ARTICLE_VERSION_ID
FROM   OKC_ARTICLE_VARIABLES v
WHERE  v.ARTICLE_VERSION_ID = :article_version_id;

A second pattern performs a reverse lookup, identifying every clause version that references a particular business variable:

SELECT a.ARTICLE_VERSION_ID
FROM   OKC_ARTICLE_VARIABLES a
WHERE  a.VARIABLE_CODE = :variable_code;

Reporting scenarios include impact analysis before modifying or deleting a business variable (to see which clause versions would be affected), auditing which variables a contract template exposes, and validating that all embedded tokens in clause text were successfully extracted. Because rows are system-generated, they are valuable for troubleshooting template rendering issues and confirming that a clause version's variable set is complete and consistent.

Related Objects

The most significant related objects are the two foreign key targets and the closely coupled clause structures:

  • OKC_ARTICLE_VERSIONS — joined on ARTICLE_VERSION_ID = OKC_ARTICLE_VERSIONS.ARTICLE_VERSION_ID. Parent clause version that owns the extracted variables.
  • OKC_BUS_VARIABLES_B — joined on VARIABLE_CODE = OKC_BUS_VARIABLES_B.VARIABLE_CODE. Definition of the business variable referenced in the clause text.
  • OKC_ARTICLES_B / OKC_ARTICLES_TL — the parent clause (article) definitions to which article versions belong, useful for tracing variables back to the base clause.
  • OKC_ARTICLE_VERSIONS_TL — translated clause version text that contains the embedded variables extracted into this table.
  • OKC_CONTRACTS and related contract tables — provide the broader contract context in which clause versions and their variables are applied.

Together these objects support the contract authoring and document generation flow, where clause text is parsed, variables are extracted into OKC_ARTICLE_VARIABLES, and values are subsequently resolved at contract generation time.