Search Results insert_mmtt




Overview

INV_UTIL is a utility PL/SQL package owned by the APPS schema in Oracle E-Business Suite. It is classified under the ETRM as a UTIL API, indicating that it provides low-level, reusable helper operations rather than a full business transaction API. The package is defined with AUTHID CURRENT_USER, meaning its procedures execute with the privileges of the calling session rather than the defining schema, a pattern common to internal inventory utilities that are invoked from within trusted application code.

The business function of INV_UTIL centers on staging inventory transaction data. Its procedures insert records into the temporary interface tables that Oracle Inventory uses during the material transaction processing cycle. These temp tables hold unvalidated transaction lines, serial numbers, and lot assignments before the transaction manager processes them into the final transaction tables. By centralizing these insert operations, INV_UTIL allows other inventory programs and APIs to populate the staging tables consistently, applying the standard API validation and message-handling conventions established by FND_API.

Key Procedures and Functions

The ETRM metadata documents three procedures in this package:

  • INSERT_MMTT — Inserts a row into MTL_MATERIAL_TRANSACTIONS_TEMP, the primary staging table for material transactions. Its documented input includes the standard API parameters (API version, initialization message list, commit flag, and validation level) plus a record typed against the MTL_MATERIAL_TRANSACTIONS_TEMP%ROWTYPE. The procedure accepts the complete transaction record with all its transaction attributes, quantities, and references. Its documented outputs include the transaction header ID, the transaction temp ID, the standard return status, and the message count and message data used by the calling program to interpret any validation errors.
  • INSERT_MTLT — Inserts a row into MTL_TRANSACTION_LOTS_TEMP, the staging table for lot-controlled transaction detail. In the Oracle Inventory transaction model, lot and serial detail are staged separately from the parent transaction line, so this procedure supports the lot-level component of a material movement. As with INSERT_MMTT, it accepts an FND_API parameter set and a record typed against MTL_TRANSACTION_LOTS_TEMP%ROWTYPE, and it returns the standard API status and message outputs.
  • INSERT_MSNT — Inserts a row into MTL_SERIAL_NUMBERS_TEMP, the staging table for serial number assignments. This is the procedure associated with the search term "insert_msnt." It serves the serial-controlled counterpart to INSERT_MTLT, allowing callers to stage serial number detail for a transaction before validation and processing occur.

All three procedures are public. The ETRM does not document the full parameter lists for INSERT_MTLT and INSERT_MSNT, but their design follows the same API contract as INSERT_MMTT: standard FND_API control parameters in, a table-typed record in, and standard status and message parameters out.

Tables Accessed

The documented tables referenced through APPS synonyms are:

  • MTL_MATERIAL_TRANSACTIONS_TEMP — written by INSERT_MMTT; the staging table for material transaction lines.
  • MTL_TRANSACTION_LOTS_TEMP — written by INSERT_MTLT; staging for lot-level transaction detail.
  • MTL_SERIAL_NUMBERS_TEMP — written by INSERT_MSNT; staging for serial number assignments.
  • MTL_MATERIAL_TRANSACTIONS_S — the transaction sequence/header source referenced in the insert logic, most likely to derive the header identifier returned to the caller.
  • MTL_TRANSACTION_TYPES — the transaction type reference table, consulted to validate or classify the transaction being staged.
  • DUAL — used for single-row evaluations, typically sequence references or constant lookups.

Usage Notes

INV_UTIL is an internal utility rather than a primary integration API. The ETRM records zero packages referencing it, which indicates that it is not part of the standard public API call graph; instead it is used internally by inventory transaction processing logic and by custom code that must stage transactions directly. Typical invocation scenarios include Oracle Inventory forms and concurrent programs that build temp records before calling the transaction manager, and custom PL/SQL routines that follow the Oracle transaction open interface pattern. Because the package is AUTHID CURRENT_USER and writes directly to interface tables, callers are responsible for populating complete, valid records, honoring the p_api_version, p_commit, and p_validation_level conventions, and checking x_return_status and the message buffer before committing or continuing processing. Direct calls should generally be reserved for cases where no supported public inventory API exists, as bypassing higher-level validation can produce transactions that fail during processing.