Information Schema: New columns in output for QUERY_HISTORY, QUERY_HISTORY_BY_* functions

Attention

This behavior change is in the 2024_02 bundle.

For the current status of the bundle, refer to Bundle History.

When this behavior change bundle is enabled, the output of the QUERY_HISTORY , QUERY_HISTORY_BY_* functions includes the following new column(s):

Column nameData typeDescription
TRANSACTION_IDNUMBER

ID of the transaction that contains the statement or 0 if the statement is not executed within a transaction.

QUERY_ACCELERATION_BYTES_SCANNEDNUMBERNumber of bytes scanned by the query acceleration service.
QUERY_ACCELERATION_PARTITIONS_SCANNEDNUMBERNumber of partitions scanned by the query acceleration service.
QUERY_ACCELERATION_UPPER_LIMIT_SCALE_FACTORNUMBERUpper limit scale factor that a query would have benefited from.
BYTES_WRITTEN_TO_RESULTNUMBER

Number of bytes written to a result object. For example, select * from ... would produce a set of results in tabular format representing each field in the selection.

In general, the results object represents whatever is produced as a result of the query, and BYTES_WRITTEN_TO_RESULT represents the size of the returned result.

ROWS_WRITTEN_TO_RESULTNUMBER

Number of rows written to a result object. For CREATE TABLE AS SELECT (CTAS) and all DML operations, this result is 1. The values in the ROWS_INSERTED, ROWS_UPDATED, and ROWS_DELETED columns reflect the number of rows actually inserted, updated, or deleted.

For more information, see ROWS_PRODUCED column deprecated.

ROWS_INSERTEDNUMBERNumber of rows inserted by the query.
QUERY_RETRY_TIMENUMBER

Total execution time (in milliseconds) for query retries caused by actionable errors. For more information, see Query retry columns.

QUERY_RETRY_CAUSEVARCHAR

Error that caused the query to retry. If there is no query retry, the field is NULL. For more information, see Query retry columns.

FAULT_HANDLING_TIMENUMBER

Total execution time (in milliseconds) for query retries caused by errors that are not actionable. For more information, see Query retry columns.

These columns are added as the last (right-most) columns in the output.

For more information, see also QUERY_HISTORY view (Account Usage): Changes to columns and new columns.

Ref: 1431, 1524, 1540