Search Results copy_batch




Overview

GHG_TRANSACTION_BATCHES_PKG is an Oracle E-Business Suite PL/SQL package owned by the APPS schema that supports the Greenhouse Gas (GHG) transaction batching functionality delivered with Oracle E-Business Suite release 12.1.1 and 12.2.2. The package encapsulates the core data manipulation logic for the GHG_TRANSACTION_BATCHES_ALL entity, which groups related greenhouse gas transactions into logical batches for reporting, calculation, and audit purposes. It is declared with AUTHID CURRENT_USER, meaning that privileges are evaluated against the invoking user rather than the package owner. The package is a low-level API of type OTHER and serves as the programmatic foundation for maintaining batch header records, including insert, update, delete, and lock operations across the batch lifecycle. It also provides higher-level business operations such as copying an existing batch and reversing a batch, which are central to correcting, duplicating, or adjusting GHG data sets within the ETRM environment.

Key Procedures and Functions

  • INSERT_ROW — Creates a new row in the GHG transaction batches entity, accepting the full set of batch attributes including batch number, type, sub type, vendor and vendor site, description, status, reversal information, operating unit, set of books, and standard WHO audit columns. An additional flag indicates whether the call originated from an API.
  • UPDATE_ROW — Modifies an existing batch record identified by its row identifier, updating the same attribute set exposed by INSERT_ROW.
  • DELETE_ROW — Removes a batch record by transaction batch identifier.
  • LOCK_ROW — Acquires a row-level lock on a batch record for the duration of the calling transaction, ensuring serialized access during concurrent updates.
  • COPY_BATCH — Duplicates an existing transaction batch, taking a source batch identifier and the target batch identifier to create a new batch based on the original. This procedure is the object of interest for the "copy_batch" search.
  • REVERSE_BATCH — Reverses a previously processed transaction batch, supporting correction and cancellation scenarios.

Tables Accessed

  • GHG_TRANSACTION_BATCHES_ALL — The primary table maintained by this package; holds batch header records with operating unit partitioning via the ALL naming convention.
  • GHG_TRANSACTIONS_ALL and GHG_TRANSACTIONS_S — Referenced during copy and reverse operations to propagate or adjust the underlying transaction records associated with a batch.
  • GHG_TRANSACTION_DETAILS_ALL — Accessed to replicate or update the detailed line information belonging to transactions within a batch.

Usage Notes

This package is typically invoked indirectly through the GHG ETRM application forms, concurrent programs, and other delivered PL/SQL packages rather than directly by end users. It is referenced by one other package in the ETRM schema, indicating that it forms a building block for higher-level GHG batch processing logic. Custom integrators may call COPY_BATCH to programmatically duplicate a batch when reproducing calculation scenarios or migrating configurations between environments, and REVERSE_BATCH when undoing batch impacts. Because the package runs with AUTHID CURRENT_USER, callers must hold the appropriate object and table privileges. Direct DML against the underlying tables should be avoided in favor of these documented procedures to preserve audit columns and business validation. As with all ETRM APIs, customers should validate behavior against their specific patch level, since the header indicates incremental versioning consistent with ongoing EBS maintenance.