16.20 - Example: Logging an XML Plan with VERBOSE EXPLAIN and DETAILED STATSUSAGE Collections in the Same Request - Teradata Database - Teradata Vantage NewSQL Engine

Teradata Vantage™ SQL Data Definition Language Syntax and Examples

Product
Teradata Database
Teradata Vantage NewSQL Engine
Release Number
16.20
Published
March 2019
Language
English (United States)
Last Update
2019-05-24
dita:mapPath
wkf1512081455740.ditamap
dita:ditavalPath
TD_DBS_16_20_Update1.ditaval

This example uses the same table and COLLECT STATISTICS request as Example: Logging an XML Plan with VERBOSE EXPLAIN and DETAILED STATSUSAGE Collections.

Log Object, SQL, Step Details, Verbose Explain, Statistics Details, and Statistics Usage information on user_1:

     BEGIN QUERY LOGGING WITH VERBOSE XMLPLAN, 
                              DETAILED STATSUSAGE ON user_1;

Update the employee table, setting the salary for employee John to $40,000:

     UPDATE employee 
     SET SALARY=40000 
     WHERE emp_name='John';

This request reports Verbose XMLPLAN, Statistics Details, and Statistics Usage rules as TRUE:

     SHOW QUERY LOGGING ON user_1;

Terminate logging on user_1:

     END QUERY LOGGING ON user_1;