Search Results set_to_subinventory




Overview

INV_CACHE is a global PL/SQL cache package within the Oracle E-Business Suite Inventory (INV) module. It is not a business-facing API in the conventional sense; rather, it is an internal caching and state-management package used by the Inventory transaction engine, pick release logic, move order processing, and cross-docking features to hold record-level data in session-scoped package globals. The package exposes a large collection of %ROWTYPE anchored variables—such as org_rec, item_rec, mmtt_rec, mol_rec, wdd_rec, and oola_rec—and provides setter functions that populate these globals from database queries so that downstream processing can reference them without repeated SELECT statements.

The object appears in ETRM 12.2.2 with an API classification of OTHER and is also present in 12.1.1 with the same cached-record design. The $Header line (INVCACHS.pls 120.3 2007/12/25) and the associated bug references (4171297, 4258360, 4951639) confirm that the package was maintained across the 11i-to-R12 transition and enhanced for R12 crossdock pegging and move order transaction dating. It is referenced by 88 other packages, which indicates it functions as a shared, low-level dependency for a substantial portion of the Inventory and Shipping execution stack.

Key Procedures and Functions

The package contains 23 documented procedures and functions, predominantly setter routines that each load one cached record:

  • SET_ORG_REC — Populates the organizational parameters cache, overloaded to accept either an organization identifier or an organization code. The resulting org_rec is the foundational context for nearly all subsequent cache loads.
  • SET_ITEM_REC — Loads item master attributes for a given organization and item, caching item_rec (anchored to MTL_SYSTEM_ITEMS).
  • SET_TOSUB_REC / SET_FROMSUB_REC — Cache destination and source secondary inventory records into tosub_rec and fromsub_rec respectively.
  • SET_MMTT_REC — Caches a pending row from the material transactions interface (MTL_MATERIAL_TRANSACTIONS_TEMP), central to processing transaction batches.
  • SET_MOL_REC / SET_MTRH_REC — Cache a move order line and move order header, respectively, supporting move order execution and pick release.
  • SET_WDD_REC — Loads a delivery detail record keyed by move order line identifier, linking Inventory processing to Oracle Shipping.
  • SET_MSO_REC — Caches a sales order reference record from MTL_SALES_ORDERS.
  • SET_OEH_ID — Establishes the cached order header identifier used by later reference lookups.
  • SET_MTT_REC — Caches transaction type attributes from MTL_TRANSACTION_TYPES.
  • SET_WMS_INSTALLED — Sets the boolean flag indicating whether Warehouse Management System capability is installed, gating WMS-specific code paths.
  • SET_PICK_RELEASE — Establishes the pick release context flag (is_pickrelease), allowing downstream logic to branch on whether the current transaction is being executed as part of a pick release operation. This is the procedure targeted by the user search term.
  • SET_TO_LOCATOR / SET_TO_SUBINVENTORY — Cache the destination locator identifier and subinventory code used during transaction staging.
  • SET_OOLA_REC — Caches an OE_ORDER_LINES_ALL record (introduced via Bug 4171297).
  • SET_WPB_REC — Caches a picking batch record from WSH_PICKING_BATCHES, added for the R12 Crossdock Pegging project (Bug 4258360).
  • SET_LOC_REC / SET_MOQD_STATUS_REC — Support onhand material status handling, caching item location and onhand quantity detail records.
  • SET_PJM_ORG_PARMS_REC — Caches project manufacturing organization parameters from PJM_ORG_PARAMETERS.

Tables Accessed

The package reads from fifteen documented tables through APPS synonyms. Organizational context derives from MTL_PARAMETERS. Item and location context derive from MTL_SYSTEM_ITEMS and MTL_ITEM_LOCATIONS. Transaction processing draws on MTL_MATERIAL_TRANSACTIONS_TEMP, MTL_TRANSACTION_TYPES, MTL_SECONDARY_INVENTORIES, and MTL_CLIENT_PARAMETERS. Move order support uses MTL_TXN_REQUEST_HEADERS and MTL_TXN_REQUEST_LINES. Onhand material status support uses MTL_ONHAND_QUANTITIES_DETAIL. Shipping and cross-docking integration uses WSH_DELIVERY_DETAILS and WSH_PICKING_BATCHES. Order and project context use MTL_SALES_ORDERS, OE_ORDER_LINES_ALL, and PJM_ORG_PARAMETERS. Most accesses are single-row lookups populating the corresponding package global.

Usage Notes

INV_CACHE is invoked internally by the Inventory transaction manager, pick release concurrent programs, move order APIs, and Shipping integration code rather than by end users directly. Because its state resides in package globals scoped to a database session, callers must invoke the appropriate setters before referencing the cached records, and must be aware that the globals persist for the duration of the session and can be overwritten by subsequent setter calls. Custom code extending Inventory or Shipping behavior should treat these globals as read-only after the owning Oracle process has populated them, and should not rely on cache contents being valid across unrelated transactions within the same session.