Search Results scale_batch




Overview

GME_SCALE_BATCH_PVT is the private (PVT) implementation layer of the Oracle Process Manufacturing (OPM) Process Execution batch scaling API. It belongs to the APPS schema and provides the internal logic that supports the public scaling interface used by OPM Process Execution. Its central business function is to proportionally adjust the quantities of a batch — materials, step charges, step items, and step resources — by a user-supplied scale factor, while optionally recalculating dependent dates and revalidating the batch against recipe validity rules.

The package header identifies it explicitly as the "Private layer for Scale batch API," authored by Oracle in January 2001 (file GMEVSCBS.pls). In the Oracle EBS 12.1.1 and 12.2.2 architecture it is not intended for direct invocation by end users; it is consumed by the public scaling API and by four other packages that depend on it. The source declares AUTHID CURRENT_USER, meaning it executes with the privileges of the calling user rather than as definer rights.

Key Procedures and Functions

  • SCALE_BATCH (overload 1) — Accepts a batch header record and a scale factor, together with control parameters governing primaries handling, quantity type, validity rule enforcement, date recalculation, and workday calendar use. Returns an exception material table, the updated batch header record, and a return status.
  • SCALE_BATCH (overload 2) — An extended overload that additionally accepts an input material details table and returns an output material details table alongside the exception table, updated header, and return status. This overload supports scaling of explicitly supplied material detail collections.
  • THEORETICAL_YIELD_BATCH — Computes the theoretical yield for a batch given the batch header record and a scale factor, returning a status indicator.
  • GET_TOTAL_QTY — A function that derives a total quantity from a supplied material details table for a given batch header. This is the object the user searched for; it is used internally to compute aggregate material quantities during the scaling calculation.
  • SCALE_STEP_AND_RSRC — Handles scaling of batch steps and their associated resources as part of the overall scaling operation.

Tables Accessed

The package reads and writes a range of OPM and shared inventory tables through APPS synonyms. Core batch data is held in GME_BATCH_HEADER, with step-level detail in GME_BATCH_STEPS, GME_BATCH_STEP_CHARGES, GME_BATCH_STEP_ITEMS, and GME_BATCH_STEP_RESOURCES. Material detail is sourced from GME_MATERIAL_DETAILS and FM_MATL_DTL. Validity and status information come from GMD_RECIPE_VALIDITY_RULES and GMD_STATUS. Routing data is read from GMD_ROUTINGS_B. Temporary working sets are staged in GME_EXCEPTIONS_GTMP and GME_RESOURCE_TXNS_GTMP. Item and unit-of-measure validation uses IC_ITEM_MST, MTL_SYSTEM_ITEMS_KFV, and SY_UOMS_MST.

Usage Notes

GME_SCALE_BATCH_PVT is invoked indirectly. OPM Process Execution forms and the public scaling API call into this private layer to perform batch scaling; it is also referenced by four other packages within the OPM suite. Because it is classified as a PVT object, Oracle does not guarantee its signature across releases, and custom code should call the public wrapper rather than this package directly. When extending or debugging scaling behavior, the GET_TOTAL_QTY function is the entry point for understanding how aggregate material quantities are calculated before the scale factor is applied.