16.10 - SQL Statements to Control Logging - Teradata Database

Teradata Database Administration

Product
Teradata Database
Release Number
16.10
Release Date
April 2018
Content Type
Administration
Publication ID
B035-1093-161K
Language
English (United States)

Start and stop logging with the Teradata SQL statements BEGIN QUERY LOGGING, REPLACE QUERY LOGGING, and END QUERY LOGGING. Only a user with EXECUTE privilege on DBC.DBQLAccessMacro can execute the statements.

You cannot issue a BEGIN/REPLACE/END QUERY LOGGING statement while running in ANSI session mode. In Teradata session mode, you cannot issue a BEGIN/REPLACE/END QUERY LOGGING statement within a BT/ET transaction. Instead, use these statements outside a BT/ET transaction or, for ANSI session mode, log off and set the transaction mode to Teradata session mode.