17.00 - Usage Notes - Teradata Database

Teradata Vantageā„¢ - Data Dictionary

prodname
Advanced SQL Engine
Teradata Database
vrm_release
17.00
created_date
June 2020
category
Administration
Programming Reference
featnum
B035-1092-170K

QRYLogXMLDocV provides a view into DBQLXMLTbl that combines multiple rows of XMLTextInfo with the same QueryID into a single XMLTextDoc document.

In a future release the XMLTextInfo column in base table DBQLXMLTbl will change its data type from VARCHAR to CLOB type casted to Teradata XML type. To ensure your applications remain compatible with this future enhancement Teradata recommends using the QryLogXMLDocV view instead of QryLogXMLV.

QRYLogXMLDocV view shows query plans and statistics usage information in an XML document. This view combines multiple rows of XMLTextInfo with the same QueryID into a single XMLTextDoc document. These BEGIN QUERY LOGGING or REPLACE QUERY LOGGING options populate the QryLogXMLDocV view:

  • WITH XMLPLAN
  • WITH STATSUSAGE

Possible Values for HasXMLPlanData, HasStatsUsageData, HasVerboseData, and HasDetailedStatsData

For these columns, a value of Y or N can be specified. If you specify Y, the data is contained in the XMLTextInfo column on behalf of the specific logging [Option], where Option represents the STATSUSAGE or XMLPlan.

Possible Values for XMLDocType

Teradata recommends that you use the Has[Option]Data and [Option]Enabled columns rather than the XMLDocType column directly, where Option represents the STATSUSAGE or XMLPlan. Queries against these columns allow you to specify a Y or N value rather than bit mapped values. For more information about these columns, see "Possible Values for HasXMLPlanData, HasStatsUsageData, HasVerboseData, and HasDetailedStatsData" (above) or see "Possible Values for XMLPlanEnabled, StatsUsageEnabled, VerboseEnabled, and DetailedStatsEnabled" (below).

Possible Values for XMLPlanEnabled, StatsUsageEnabled, VerboseEnabled, and DetailedStatsEnabled

For these columns, a value of Y or N can be specified. If you specify Y, the [Option], where Option represents the STATSUSAGE or XMLPlan, was enabled when the data in XMLTextInfo was logged.