Search Results get_doc_number




Overview

GME_ERES_UTILS is a utility package body owned by the APPS schema in Oracle E-Business Suite, delivered as part of the Oracle Process Manufacturing (OPM) product family. Its stated purpose, per the embedded header block, is to hold the routines required to support ERES (Electronic Records and Electronic Signatures) output during XML mapping, and it is consumed by the gateway product. The package was authored by Shrikant Nene of OPM Development and dates from August 2002, with the current header revision recorded in GMEERESB.pls. In terms of API classification it is registered as OTHER, meaning it is an internal helper package rather than a formal public API with a committed interface.

The package exists to translate internal OPM batch identifiers into the human-readable descriptors that must appear on ERES-generated XML documents. Regulatory-facing output such as batch records and electronic signature trails requires consistent, meaningful document identifiers rather than surrogate keys, and GME_ERES_UTILS supplies those values in a centralized, reusable form.

Key Procedures and Functions

  • GET_BATCH_NUMBER — Returns the plant code and batch number corresponding to a given batch identifier. Internally it declares a cursor named get_doc_number that selects organization_code || ' ' || batch_no from gme_batch_header_vw for the supplied batch. This is directly relevant to the search term "get_doc_number": although GET_DOC_NUMBER is not a standalone documented packaged procedure, it is the private cursor name embedded inside GET_BATCH_NUMBER that produces the document number string used in ERES XML mapping. A user or developer searching this term is almost certainly looking for this concatenation logic.
  • GET_PHANTOM_OR_NOT — Determines whether a specified batch acts as a phantom batch. It queries gme_material_details for any row where phantom_id equals the supplied batch identifier, short-circuiting on the first match. When such a row exists, the routine returns the message string retrieved via fnd_message.get_string('GME','GME_PHANTOM'); otherwise it returns NULL. This allows the XML output to flag phantom batches distinctly from regular ones.

Both routines use the NOCOPY hint on their OUT parameters, an optimization typical of high-volume utility code. No parameter lists are documented beyond the identifiers described above.

Tables Accessed

  • GME_MATERIAL_DETAILS (via APPS synonym) — read by GET_PHANTOM_OR_NOT. It is queried solely to detect the presence of a material detail row referencing the batch as a phantom parent, establishing the phantom status of the batch.
  • GME_BATCH_HEADER_VW (referenced in the package source) — read by the get_doc_number cursor inside GET_BATCH_NUMBER to obtain the concatenated organization code and batch number. This view is the documented source of the ERES document number format.

Neither table is modified by this package; GME_ERES_UTILS is strictly a read-only utility.

Usage Notes

The package is invoked indirectly rather than through end-user navigation. The header text explicitly states it supports ERES output during XML mapping and is used by the gateway product, so in practice it is called from the OPM XML gateway mapping logic at the moment ERES documents are assembled. It is not referenced by any other documented package (referenced-by count is zero), which confirms it is a leaf-level helper.

In Oracle EBS 12.1.1 and 12.2.2 customers may also call these routines from custom PL/SQL that renders batch documentation, provided the APPS schema and appropriate privileges are available. Because the package is classified as OTHER and carries a "noship" header marker, it should be treated as an unsupported internal interface: the cursor name get_doc_number and the concatenation format are implementation details that Oracle may change without notice. Developers extending ERES output should reference GET_BATCH_NUMBER rather than attempting to call any doc-number routine directly, since none is exposed as a public packaged procedure.