Search Results inv_sales_orders




Overview

The APPS.INV_SALESORDER package is a public Oracle Inventory (INV) API that manages sales order records represented in the MTL Sales Orders key flexfield. Within Oracle E-Business Suite 12.1.1 and 12.2.2, MTL Sales Orders serve as the Inventory-side key flexfield capable of storing and validating sales order references. This package provides a supported programmatic interface for creating, deleting, and retrieving information from that flexfield structure, as well as for maintaining synchronization with Oracle Order Management (OM). It is classified under the ETRM metadata as an OTHER API owned by APPS, with a public scope, active lifecycle, and the business entity category INV_SALES_ORDERS. Because sales order identifiers are consumed across inventory transactions, receiving, and shipping flows, this package acts as the controlled gateway between the Order Management order headers and the Inventory sales order flexfield representation.

Key Procedures and Functions

  • CREATE_SALESORDER — Creates a sales order record in the MTL Sales Orders flexfield. The procedure accepts a segment-based definition of the order (order number, order type or header identifier, and order source), performs flexfield validation, and returns the generated sales order identifier together with return status and message stack details. A validation mode flag controls whether full flexfield API validation is applied or a faster manual creation path is used.
  • GET_OEHEADER_FOR_SALESORDER — Returns the corresponding Order Management order header for a given sales order flexfield record, supporting reverse lookups from Inventory to OM.
  • GET_SALESORDER_FOR_OEHEADER — Returns the sales order flexfield identifier associated with a given OM order header, supporting forward lookups from OM to Inventory.
  • SYNCH_SALESORDERS_WITH_OM — Synchronizes sales order flexfield records with their Order Management counterparts, ensuring referential consistency between the two modules.
  • GET_HEADER_ID — Retrieves the order header identifier used in sales order processing.
  • CREATE_MTL_SALES_ORDERS_BULK — Performs bulk creation of MTL Sales Orders records, intended for high-volume processing where individual API calls would be inefficient.
  • DELETE_MTL_SALES_ORDERS_BULK — Performs bulk deletion of MTL Sales Orders records, complementing the bulk creation routine for large-scale maintenance operations.

Tables Accessed

The package reads and writes MTL_SALES_ORDERS and MTL_SALES_ORDERS_S, the base and translation/segment tables backing the sales order key flexfield. It interacts with OE_ORDER_HEADERS and OE_ORDER_HEADERS_ALL to resolve and synchronize Order Management order headers, and with OE_TRANSACTION_TYPES_ALL and OE_TRANSACTION_TYPES_TL to validate and translate order types. FND_LANGUAGES supports language-dependent lookups, DUAL is used for trivial single-row selection, and PLITBLM is the PL/SQL table/index-by table type utility commonly used in Oracle EBS APIs for message and array handling. All tables are referenced through APPS synonyms.

Usage Notes

INV_SALESORDER is typically invoked from Oracle Inventory forms and concurrent programs that need to register or validate an order reference against the sales order flexfield, and from custom PL/SQL code that must reconcile Inventory records with Order Management. It is referenced by 41 other packages, indicating broad consumption across the Order Management and Inventory integration surface. When calling CREATE_SALESORDER, the standard Oracle EBS API conventions apply: initialize the message list, inspect the returned status against FND_API.G_RET_SUCCESS, G_EXC_ERROR, and G_EXC_UNEXPECTED_ERROR, and read X_MESSAGE_DATA on failure. The full-validation flag should be left at its default unless performance-critical bulk loading justifies bypassing flexfield API validation, in which case the reduced validation path should only be used with full understanding of the flexfield rules being skipped. For large data volumes, the bulk creation and deletion routines are the appropriate entry points.