Search Results inv_third_party_stock_util




Overview

INV_THIRD_PARTY_STOCK_UTIL is a PL/SQL utility package owned by the APPS schema in Oracle E-Business Suite. It supports the third-party stock and consumption advice functionality within Oracle Inventory, providing shared helper routines that resolve organizational context, item unit-of-measure attributes, ship-to locations, and supplier information used during third-party inventory processing. The package is classified as a utility (UTIL) object in ETRM for release 12.2.2, and its status is recorded as VALID in the documented 12.1.1/12.2.2 environment. Rather than implementing a business transaction end-to-end, it consolidates common lookup logic so that the primary third-party stock processing packages — INV_THIRD_PARTY_STOCK_PVT and INV_CONSUMPTION_ADVICE_PROC — can call a single, consistent set of accessors.

Key Procedures and Functions

The ETRM metadata documents six callable units within this package. As implied by their names, their responsibilities are as follows.

  • SET_OU_CONTEXT — Establishes the operating unit context so that subsequent queries and DML in the calling session are scoped to the correct organization hierarchy.
  • GET_ORG_ID — Returns the organization identifier applicable to the current processing context, typically the inventory organization involved in the third-party stock transaction.
  • GET_PRIMARY_UOM — Retrieves the primary unit of measure for a given item, drawn from the item master, so that quantities can be expressed in the base UOM.
  • GET_UOM_CODE — Supplies the UOM code associated with a unit of measure definition, supporting conversions and validation of transactional quantities.
  • GET_LOCATION — Resolves a location, generally the ship-to or receiving location relevant to the third-party stock movement.
  • GET_VENDOR_INFO — Returns supplier (vendor) information required for third-party consumption advice and stock reporting.

Parameter lists are not reproduced here, consistent with the documented metadata; callers should reference the live package specification for exact signatures.

Tables Accessed

The package reads from several base tables through APPS synonyms. HR_ALL_ORGANIZATION_UNITS supplies organization and operating unit definitions used by SET_OU_CONTEXT and GET_ORG_ID. MTL_SYSTEM_ITEMS provides item-level attributes, principally the primary UOM and related inventory flags. MTL_UNITS_OF_MEASURE provides unit-of-measure codes and conversion context for GET_UOM_CODE and GET_PRIMARY_UOM. DBMS_APPLICATION_INFO is used for session-level context setting and debugging traceability, aligning with standard EBS instrumentation practice. The package is described as reading the documented tables; no write operations are indicated by the metadata.

Usage Notes

INV_THIRD_PARTY_STOCK_UTIL is referenced by two other packages: INV_CONSUMPTION_ADVICE_PROC, which governs the creation and processing of consumption advice records, and INV_THIRD_PARTY_STOCK_PVT, the private API layer for third-party stock transactions. The package also appears in its own dependency list, indicating internal recursive reference or overloaded calls. Because it is a utility package, it is not typically invoked directly from Oracle Forms or concurrent program definitions; instead it is called from within the third-party stock and consumption advice flows, including custom extensions that need consistent organization, UOM, location, or vendor lookups. Any custom code that invokes these routines should first ensure the operating unit context is initialized, since the accessor functions rely on that context. The dependency on DBMS_APPLICATION_INFO suggests subprograms may annotate the session during execution, which is useful when diagnosing third-party stock processing in 12.1.1 and 12.2.2 environments.