Search Results mtl_supply_demand_temp_s




Overview

FLM_SUPPLY_DEMAND is an Oracle Applications (APPS) PL/SQL package body that supports the supply and demand processing infrastructure used by Oracle Flow Manufacturing and adjacent planning/inventory modules. Its central responsibility is to collect, stage, and expose supply and demand information for items within a given organization so that downstream availability, ATP (Available-to-Promise), and scheduling logic can consume a consolidated view of what is on hand, what is expected, and what is required. The package orchestrates data gathering from a wide range of manufacturing, inventory, and order management sources into a temporary staging table, and then provides access routines to retrieve that consolidated picture. It relies heavily on the FND_API and FND_MSG_PUB error-handling framework, indicating that it is designed as an internal API layer rather than an end-user interface. In ETRM 12.2.2 the package is documented as VALID and classified as OTHER, with twenty-one documented procedures spanning collection of supply, collection of demand, staging cleanup, and retrieval. It references the MTL_SUPPLY_DEMAND_TEMP_S staging table, which aligns with the user's search term and reflects the package's role as a supply/demand aggregator.

Key Procedures and Functions

The remaining documented procedures are internal helpers supporting the routines above; parameter signatures are not published in the ETRM metadata and should not be assumed.

Tables Accessed

The package reads and writes a broad set of APPS synonyms. Supply and balance data is drawn from MTL_ONHAND_QUANTITIES, MTL_SUPPLY, MTL_USER_SUPPLY, MTL_MATERIAL_TRANSACTIONS_TEMP, and MTL_SECONDARY_INVENTORIES. Demand is sourced from MTL_DEMAND, MTL_DEMAND_INTERFACE, MTL_USER_DEMAND, and OE_ORDER_LINES. Bill-of-material explosion and component logic relies on BOM_BILL_OF_MATERIALS, BOM_EXPLOSIONS, BOM_INVENTORY_COMPONENTS, BOM_COMMON_DEFINITIONS, and BOM_CALENDAR_DATES. WIP-related supply and demand comes from WIP_DISCRETE_JOBS, WIP_REPETITIVE_ITEMS, WIP_REPETITIVE_SCHEDULES, WIP_FLOW_SCHEDULES, WIP_OPERATIONS, and WIP_REQUIREMENT_OPERATIONS. ATP rules are read from MTL_ATP_RULES, MTL_ATP_RULES_S, MTL_GROUP_ATPS_VIEW, and MTL_GROUP_ITEM_ATPS_VIEW. Item and organization context comes from MTL_SYSTEM_ITEMS, MTL_PARAMETERS, and the MRP_CALENDAR. The staging target is MTL_SUPPLY_DEMAND_TEMP_S, which ties directly to the user's search term and serves as the working store for the collection routines. Several of these are package references (BOM_COMMON_DEFINITIONS, FND_API, FND_MSG_PUB, MRP_CALENDAR, OE_INSTALL, WIP_CONSTANTS) rather than plain tables.

Usage Notes

FLM_SUPPLY_DEMAND is not referenced by any database object, meaning it is invoked from the outside — typically from Oracle Flow Manufacturing forms, concurrent programs, or custom PL/SQL calls that need a consolidated supply/demand snapshot for an organization and item. The CLEAR / COLLECT / GET sequence strongly implies a two-phase usage pattern: call CLEAR_SUPPLY_DEMAND_INFO followed by COLLECT_SUPPLY_DEMAND_INFO to refresh the staging table, then call GET_SUPPLY_DEMAND_INFO to read results. Because the package depends on FND_API and FND_MSG_PUB, callers should check the standard FND message stack for errors after each invocation. Since MTL_SUPPLY_DEMAND_TEMP_S is a temporary staging structure, callers should treat the collected data as session- or run-scoped and re-run the collection rather than persisting assumptions across calls.