REPLACE QUERY LOGGING Request | Teradata Vantage - REPLACE QUERY LOGGING Avoids the Problems of Ending an Existing Query Logging Rule Set - Analytics Database - Teradata Vantage

SQL Data Definition Language Detailed Topics

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Analytics Database
Teradata Vantage
Release Number
17.20
Published
June 2022
Language
English (United States)
Last Update
2023-07-11
dita:mapPath
vuk1628111288877.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
B035-1184
lifecycle
latest
Product Category
Teradata Vantage™

You can use an END QUERY LOGGING request like the following to end all the rules in the DBC.DBQLRuleTbl.

END QUERY LOGGING ON ALL RULES;

However, between the time all the rules have been ended and a new rule has begun with newly specified options, logging does not take place for the specified user, application, or account.

To avoid this problem, the REPLACE QUERY LOGGING statement simply replaces an existing rule using a request like one of the following.

REPLACE QUERY LOGGING WITH options ON user_name ACCOUNT = 'acct_ID'

or

REPLACE QUERY LOGGING WITH options on APPL_NAME=application_name;