BEGIN LOGGING SQL Statement | VantageCloud Lake - BEGIN LOGGING - Teradata Vantage

Teradata® VantageCloud Lake

Deployment
VantageCloud
Edition
Lake
Product
Teradata Vantage
Published
January 2023
ft:locale
en-US
ft:lastEdition
2024-12-11
dita:mapPath
phg1621910019905.ditamap
dita:ditavalPath
pny1626732985837.ditaval
dita:id
phg1621910019905

Starts auditing SQL requests that attempt to access data.

The system creates a log entry when checking privileges on the SQL request.

ANSI Compliance

This statement is a Teradata extension to the ANSI SQL:2011 standard.

Other SQL dialects support similar non-ANSI standard statements with names such as START LOGGING.

Required Privileges

You must have the EXECUTE privilege on the DBC.AccLogRule macro to use the BEGIN LOGGING statement to initiate access logging on database objects and operations.

Privileges Granted Automatically

None.

Prerequisites

When you initially set up logging, before you can use the BEGIN LOGGING statement, you must run the DIPACC script to create the DBC.ACCLogRule macro, which allows you to create logging rules in the DBC.AccLogRuleTbl using BEGIN LOGGING statements.