Search Results clear_def_lineset_cache




Overview

The APPS.ONT_DEF_LINESET_DEF_UTIL package body is an internal utility (API classification: UTIL) shipped within the Oracle Order Management (ONT) module. It supports the defaulting framework that drives Order Management's line-level defaulting rules, specifically the resolution of the DEFAULT_LINE_SET attribute against the view OE_AK_DEFAULT_LINE_SET_V. The package encapsulates the low-level logic required to extract typed attribute values from a default line set record and to maintain a lightweight in-memory cache of that record for the duration of a session. It was created in March 2009 (Header: OEXDFWKB.pls 115.0) and appears in both Oracle EBS 12.1.1 and 12.2.2 environments. Because the package exposes generic accessors rather than a formal public API, it functions primarily as a supporting helper invoked by the defaulting engine rather than as a standalone integration point.

Key Procedures and Functions

The ETRM metadata documents three program units, corresponding directly to the source excerpt.

  • GET_ATTR_VAL_VARCHAR2 — Returns the character representation of a requested attribute from a supplied OE_AK_DEFAULT_LINE_SET_V record. It recognizes the attribute code DEFAULT_LINE_SET; if the record's value equals the FND_API "missing" sentinel it returns NULL, otherwise it returns the stored value. Any unrecognized attribute code also yields NULL.
  • GET_ATTR_VAL_DATE — The date-typed counterpart of the above. When the requested attribute is DEFAULT_LINE_SET and the stored value is present, it converts the value using the format mask RRRR/MM/DD HH24:MI:SS and returns a DATE; otherwise it returns NULL. This is the routine most frequently searched under the term get_attr_val_date.
  • SYNC_DEF_LINESET_CACHE — Populates the package-global cached record by querying OE_AK_DEFAULT_LINE_SET_V for the supplied DEFAULT_LINE_SET value. It returns 0 immediately when the input is the FND_API missing sentinel.

A fourth helper, CLEAR_DEF_LINESET_CACHE, appears in the source body to reset the cached record but is not enumerated among the documented procedures.

Tables Accessed

The package operates against the defaulting view OE_AK_DEFAULT_LINE_SET_V, referenced in 12.2.2 via its APPS synonym. The global constant g_database_object_name is set to this view name. SYNC_DEF_LINESET_CACHE performs a SELECT * filtered by DEFAULT_LINE_SET, and the two accessor functions consume a %ROWTYPE record drawn from the same view. No other base tables are named in the documented source, and the metadata records no additional referenced tables for this unit.

Usage Notes

This package is invoked from within the Order Management defaulting framework whenever line-set defaults must be converted to typed values or cached for repeated access. Practically, it is reached through the Order Management Transaction (OMT) or Sales Order forms during defaulting-rule execution, and indirectly whenever the Ont defaulting engine resolves DEFAULT_LINE_SET. The ETRM metadata indicates it is referenced by exactly one other package, confirming its role as a narrow internal helper rather than a broadly reused API. Custom code should not call these routines directly unless replacing or extending the shipped defaulting logic, since the function signatures depend on the exact row type of OE_AK_DEFAULT_LINE_SET_V and on FND_API sentinel conventions. Developers distinguishing get_attr_val_date from get_attr_val_varchar2 should note that both read the same underlying column; only the return typing and date conversion format differ. Because the cache is session-scoped, callers must invoke SYNC_DEF_LINESET_CACHE (or CLEAR_DEF_LINESET_CACHE) to refresh state between line sets.