Search Results zx_errors_gt




Overview

ZX_ERRORS_GT is a global temporary table owned by the ZX schema, the foundation of the Oracle E-Business Tax (E-Business Tax / ETRM) module. As its name implies, the object serves as a transient error-collection buffer used during tax processing: when the tax engine determines that a transaction, line, or event does not satisfy the validation rules required to compute tax, it writes diagnostic rows here so that calling programs, concurrent requests, and end users can retrieve and act upon the failure. The table is populated and consumed entirely within a single session or request lifecycle; its rows are not intended for permanent retention and are typically purged on commit or session exit depending on the ON COMMIT clause configured for the temporary table.

In Data Vault modeling terms, the metadata classifies ZX_ERRORS_GT as a standalone object, meaning the mining heuristic did not identify it as a hub, link, or satellite. This is consistent with its role as a procedural diagnostic structure rather than a persistent business entity: it carries descriptive error context (MESSAGE_TEXT) tied to runtime processing, not historical states of a durable business key. It should therefore be treated as a staging/diagnostic artifact rather than a candidate for a Data Vault hub or satellite in any downstream warehouse design.

Key Information Stored

The documented physical schema for ETRM 12.2.2 contains ten columns. The most significant are:

  • APPLICATION_ID — the owning application identifier for the transaction being processed, used to scope the error to the correct product (e.g., Receivables, Payables, Purchasing).
  • ENTITY_CODE and EVENT_CLASS_CODE — identify the tax event subject and its classification, enabling the tax engine to apply the correct rules.
  • TRX_ID — the transaction identifier under which the error occurred.
  • TRX_LINE_ID — the specific transaction line; documented as a foreign key to CN_TRX_LINES_ALL.
  • TRX_LINE_DIST_ID — the distribution line context, where applicable.
  • TAX_LINE_ID — the tax line being computed; documented as a foreign key to ZX_LINES.
  • SUMMARY_TAX_LINE_NUMBER — the human-readable tax line number used for reporting and reconciliation.
  • TRX_LEVEL_TYPE — indicates whether the error pertains to the header, line, or distribution level.
  • MESSAGE_TEXT — the actual error message returned to the caller, the primary diagnostic payload.

No surrogate primary key or unique index is documented for this table in the ETRM metadata. Because it is a temporary diagnostic structure, rows are not uniquely identified by a system-generated key; business-key candidates would be the combination of TRX_ID, TRX_LINE_ID, and TAX_LINE_ID, though uniqueness is not enforced by the database.

Common Use Cases and Queries

The table is primarily consumed immediately after a tax calculation call to determine whether errors were raised. A typical pattern is to query it by transaction context:

  • Error retrieval after calculation: SELECT message_text, trx_line_id, tax_line_id FROM zx_errors_gt WHERE trx_id = :p_trx_id;
  • Line-level diagnostics: SELECT trx_line_id, trx_line_dist_id, summary_tax_line_number, message_text FROM zx_errors_gt WHERE application_id = :p_app AND entity_code = :p_entity ORDER BY trx_line_id;
  • Reporting: joining back to ZX_LINES on TAX_LINE_ID to reconcile failed tax lines with successfully calculated ones.
  • Debugging tax rules: grouping by ENTITY_CODE and EVENT_CLASS_CODE to identify recurring configuration failures.

Because it is a global temporary table, any query must be executed in the same session or request that populated it; otherwise it will return no rows.

Related Objects

  • CN_TRX_LINES_ALL — joined via ZX_ERRORS_GT.TRX_LINE_ID = CN_TRX_LINES_ALL.TRX_LINE_ID, providing transaction line detail for error context.
  • ZX_LINES — joined via ZX_ERRORS_GT.TAX_LINE_ID = ZX_LINES.TAX_LINE_ID, linking the error to the tax line being calculated.
  • ZX_LINES_DET_FACTORS — tax determination detail, often inspected alongside error rows during debugging.
  • ZX_REC_NREC_DIST — tax distribution records used in reconciliation reporting.
  • ZX_API_PUB / ZX_TAX_API_PUB — the public APIs that populate and return errors originating from this table.

Together these objects form the diagnostic layer around the E-Business Tax calculation engine, allowing implementers to trace a failed tax determination from the transaction line down to the specific rule violation recorded in ZX_ERRORS_GT.