Search Results get_reserved_qty
Overview
CTO_WIP_WRAPPER is an Oracle Manufacturing utility package owned by APPS and declared with AUTHID CURRENT_USER. It provides the core programmatic logic required to create and manage work orders for Assemble-to-Order (ATO) configurations within Oracle E-Business Suite. The package header identifies its primary purpose as generating the utilities needed to create work orders for ATO configurations, bridging the configuration captured on the sales order side with the discrete and flow manufacturing execution model on the shop floor.
The package operates at the intersection of Oracle Order Management and Oracle Work in Process. When a configured item is ordered, the system must translate the sales order configuration into a corresponding work order structure, and it must manage the reservation relationship between the resulting work order and the demand line that spawned it. CTO_WIP_WRAPPER encapsulates that translation and reservation logic so that it can be reused by concurrent programs, order management workflows, and custom extensions. The source header footer dates the original file to 2002 (CTOWIPWS.pls, version 115.8), confirming the package has been a stable element of the ATO fulfillment stack across the 11i and R12 releases, including 12.1.1 and 12.2.2.
Key Procedures and Functions
The ETRM metadata documents four procedures and functions in the package. Each addresses a distinct stage of ATO work order processing.
- GET_ORDER_LINES — Retrieves the sales order line data used to drive work order creation. Its parameters include the operating unit organization, an offset in days, a load type distinguishing config, non-config, or both, a class code and status type used for job creation, an order number, a line id, and the concurrent request context (request id, program id, login id). It therefore serves as the selection and driving routine for the ATO job creation process.
- RESERVE_WO_TO_SO — Establishes the reservation linkage between the generated work order supply and the originating sales order demand. This is the mechanism by which work order output is tied back to the specific order line it is intended to satisfy.
- GET_RESERVED_QTY — Returns the quantity already reserved against a work order or demand reference. This is the function most frequently sought by developers investigating reservation balances, and it supplies the reserved quantity used in availability and fulfillment decisions.
- GET_NOTINV_QTY — Returns the quantity that is not available within inventory, complementing the reserved quantity calculation when assessing how much of a configured demand can be met from existing stock versus newly created supply.
These four routines together cover the life cycle of ATO supply: identifying eligible order lines, creating the associated work orders through the interface, reserving the resulting supply, and reporting reserved and non-inventory quantities for downstream consumption.
Tables Accessed
The package references a broad set of tables through APPS synonyms, spanning order management, bills of material, inventory, and work in process.
- OE_ORDER_HEADERS_ALL and OE_ORDER_LINES_ALL — supply the sales order header and line context, including the configuration item and its line identifiers.
- OE_TRANSACTION_TYPES_TL — provides translated transaction type information used to qualify order lines.
- MTL_SALES_ORDERS — links demand references to order numbers.
- MTL_RESERVATIONS — the repository read and written by the reservation routines, holding the reservation records that tie work order supply to sales order demand.
- MTL_SYSTEM_ITEMS — validates and attributes item master information for configuration and component items.
- WIP_JOB_SCHEDULE_INTERFACE and WIP_JOB_SCHEDULE_INTERFACE_S — the interface tables into which work order records are inserted for subsequent processing by WIP mass load.
- WIP_DISCRETE_JOBS, WIP_ENTITIES, and WIP_FLOW_SCHEDULES — provide visibility into existing discrete jobs and flow schedules used for reservation and quantity calculations.
- BOM_OPERATIONAL_ROUTINGS — supports routing-related processing during work order interface population.
- FND_LANGUAGES and DUAL — support translated lookups and utility expressions.
Usage Notes
CTO_WIP_WRAPPER is invoked primarily in the context of ATO work order creation and reservation processing. The package is referenced by two other packages, indicating it functions as a shared utility layer rather than a standalone entry point. Typical invocation paths include concurrent programs that select eligible configuration order lines and insert corresponding records into WIP_JOB_SCHEDULE_INTERFACE for WIP mass load, as well as order management workflows that need to reserve newly created work order supply against the originating sales order. Developers searching for get_reserved_qty should note that the function returns reserved quantity derived from reservation and work order data and is intended to be called from custom PL/SQL rather than directly from a form; callers should supply the appropriate work order or demand identifiers and treat the returned value as the currently reserved portion of supply. Because the package uses AUTHID CURRENT_USER, execute privileges and any invoker-rights behavior depend on the calling user's grants. Custom code should call the documented routines rather than manipulate MTL_RESERVATIONS or the WIP interface tables directly, to preserve the integrity of the reservation and work order creation logic.
-
APPS.GME_RESERVATIONS_PVT SQL Statements
12.2.2
-
PACKAGE: APPS.CTO_WIP_WRAPPER
12.1.1
-
PACKAGE: APPS.CTO_AUTO_PROCURE_PK
12.1.1
-
APPS.CTO_WIP_WRAPPER SQL Statements
12.1.1
-
PACKAGE BODY: APPS.CTO_WIP_WRAPPER
12.1.1
-
PACKAGE: APPS.CTO_WIP_WRAPPER
12.2.2
-
PACKAGE BODY: APPS.CTO_WIP_WRAPPER
12.2.2
-
APPS.CTO_WIP_WRAPPER SQL Statements
12.2.2
-
PACKAGE: APPS.CTO_AUTO_PROCURE_PK
12.2.2
-
PACKAGE: APPS.GME_RESERVATIONS_PVT
12.1.1
-
PACKAGE: APPS.GME_RESERVATIONS_PVT
12.2.2
-
PACKAGE BODY: APPS.GME_RESERVATIONS_PVT
12.2.2
-
APPS.CTO_WIP_UTIL SQL Statements
12.1.1
-
APPS.CTO_WIP_UTIL SQL Statements
12.2.2
-
APPS.GME_COMMON_PVT SQL Statements
12.2.2
-
PACKAGE BODY: APPS.GME_RESERVATIONS_PVT
12.1.1
-
APPS.CTO_WIP_WRAPPER dependencies on CTO_WIP_WRAPPER
12.1.1
-
APPS.CTO_WIP_WRAPPER dependencies on CTO_WIP_WRAPPER
12.2.2
-
PACKAGE BODY: APPS.CTO_WIP_UTIL
12.1.1
-
PACKAGE BODY: APPS.CTO_WIP_UTIL
12.2.2
-
APPS.GME_RESERVATIONS_PVT dependencies on GME_MATERIAL_DETAILS
12.2.2
-
PACKAGE BODY: APPS.CTO_AUTO_PROCURE_PK
12.1.1
-
APPS.CTO_WIP_UTIL dependencies on WIP_JOB_SCHEDULE_INTERFACE
12.1.1
-
APPS.GME_RESERVATIONS_PVT dependencies on GME_MATERIAL_DETAILS
12.1.1
-
PACKAGE BODY: APPS.CTO_AUTO_PROCURE_PK
12.2.2
-
APPS.GME_RESERVATIONS_PVT dependencies on FND_MSG_PUB
12.1.1
-
APPS.CTO_WIP_UTIL dependencies on WIP_JOB_SCHEDULE_INTERFACE
12.2.2
-
APPS.CTO_WIP_WRAPPER dependencies on OE_DEBUG_PUB
12.2.2
-
APPS.CTO_WIP_WRAPPER dependencies on OE_DEBUG_PUB
12.1.1
-
APPS.GME_RESERVATIONS_PVT dependencies on GME_MATERIAL_DETAILS
12.2.2
-
APPS.GME_RESERVATIONS_PVT dependencies on GME_MATERIAL_DETAILS
12.1.1
-
APPS.GME_RESERVATIONS_PVT dependencies on FND_MSG_PUB
12.2.2
-
APPS.CTO_WIP_WRAPPER dependencies on OE_ORDER_LINES_ALL
12.1.1
-
APPS.CTO_WIP_WRAPPER dependencies on OE_ORDER_LINES_ALL
12.2.2
-
APPS.GME_RESERVATIONS_PVT dependencies on FND_API
12.1.1
-
APPS.GME_RESERVATIONS_PVT dependencies on FND_API
12.2.2
-
APPS.GME_RESERVATIONS_PVT dependencies on GME_COMMON_PVT
12.1.1
-
APPS.GME_RESERVATIONS_PVT dependencies on GME_COMMON_PVT
12.2.2
-
APPS.CTO_AUTO_PROCURE_PK dependencies on OE_DEBUG_PUB
12.1.1
-
APPS.CTO_AUTO_PROCURE_PK dependencies on OE_DEBUG_PUB
12.2.2
-
PACKAGE BODY: APPS.GME_COMMON_PVT
12.2.2
-
PACKAGE BODY: APPS.CTO_OSS_SOURCE_PK
12.1.1
-
PACKAGE BODY: APPS.CTO_OSS_SOURCE_PK
12.2.2