Search Results inv_default_trolin




Overview

INV_DEFAULT_TROLIN is a public PL/SQL package in the APPS schema that supports the defaulting of transaction request (move order) line records within Oracle Inventory. Its name derives from its role: defaulting transaction request line (TROLIN) attribute values. The package declares AUTHID CURRENT_USER and is classified by ETRM as a miscellaneous API ("OTHER"), reflecting that it is not part of the formal transactional API surface exposed by INV_Move_Order_PUB and INV_Transfer_Order_PVT, but rather a supporting utility invoked by those layers.

The package exists primarily to centralize the logic that populates a INV_Move_Order_PUB.Trolin_Rec_Type record structure with validated defaults drawn from Inventory master and transaction tables. It also owns a specific piece of state management around line number generation — the subject of the bug fix recorded in the package header (bug#7126566) and the likely origin of the "get_line_number" search term that surfaced this object.

Key Procedures and Functions

ETRM documents three callable elements within INV_DEFAULT_TROLIN:

  • GET_LINE_NUMBER — Returns a unique line number for a transaction request line. Per the package header, this function increments the relevant line number when called directly by an API, guaranteeing uniqueness. When the caller is an Oracle Forms session, the increment is instead performed by the form via inv_transfer_order_pvt.increment_max_line_number, preventing spurious increments as the user navigates between lines. The package tracks the invocation context through the G_CALLED_BY_FORM variable.
  • SET_CALLED_BY_FORM — A procedure that sets the G_CALLED_BY_FORM flag, determining whether GET_LINE_NUMBER should self-increment or defer to the form-driven increment. This is the control point that distinguishes form-based from API-based line number generation.
  • ATTRIBUTES — Takes an input Trolin_Rec_Type record (defaulting to G_MISS_TROLIN_REC) and an iteration counter, and returns a populated output record. This is the core defaulting routine, deriving attribute values for a move order line from the supporting Inventory tables.

Tables Accessed

The package resolves references through APPS synonyms to the following Inventory tables:

Usage Notes

INV_DEFAULT_TROLIN is invoked indirectly rather than as a standalone entry point. Oracle Forms and the transfer order public APIs reach GET_LINE_NUMBER and ATTRIBUTES through the transactional flow, with SET_CALLED_BY_FORM used to declare the calling context before GET_LINE_NUMBER executes. Custom code should call the public INV_Move_Order_PUB / INV_Transfer_Order_PVT interfaces rather than this package directly, since its contract is tightly coupled to those callers. ETRM records that the package is referenced by one other package, confirming its role as an internal collaborator. The bug#7126566 fix ensures that line numbers remain contiguous and unique regardless of whether the flow originates in a form or through an API, which is the behavior most relevant to anyone investigating line number generation in Oracle EBS 12.1.1 and 12.2.2.