Comparing Execution Plans Visually - Visual Explain

Teradata Visual Explain User Guide

Product
Visual Explain
Release Number
15.00
Language
English (United States)
Last Update
2018-09-27
dita:id
B035-2504
lifecycle
previous
Product Category
Teradata Tools and Utilities

Comparing Execution Plans Visually

Two or more execution plans can be compared visually through the command line interface.

To compare execution plans visually, use the following command:

VEComp -vc <Execution Plan1 [Execution Plan2...]> [View Mode]

Execution Plan

{
{ Online Plan Description} ||
{-f <Offline Execution Plan file name>}
}

The first plan specified in the command is the base plan for comparison.

Table 48 describes commands for comparing execution plans visually.

 

Table 48: Examples for Comparing Execution Plans Visually 

Example

Command

Description

1

VEComp -vc -l sysB\dbc\dbc -d qcd 
-rc 73-78 -l sysA\dbc\dbc -d qcd  
-rc 75-80

Opens execution plans whose queryID is in the range
73–78 from the database qcd on server sysB, and whose queryID is in the range 75–80 from the database qcd on server sysA using CLIv2 connectivity. The plans are compared after they are opened.

In this example, if a plan with a queryID of 73 exists, it is treated as the base plan. Otherwise, the first plan found that matches the given criteria is the base plan.

2

VEComp - vc -l sysB\dbc\dbc -d qcd 
-rc 73-78

Opens and then compares execution plans whose queryID is in the range 73–78 from the database qcd on server sysB using CLIv2 connectivity.

3

VEComp -vc -l sysB\dbc\dbc -d qcd -xml
-rc 73-78

Opens and then compares execution plans captured in XML format whose queryID is in the range 73–78 from the database qcd on server sysB using CLIv2 connectivity.

Note: Only available for Teradata Database version 13.10 and later. You cannot compare XML and normal execution plans at the same time using the command line option.

4

VEComp -vc -l sysB\dbc\dbc -d qcd 
-rc 73 -l sysA\dbc\dbc -d qcd 
-rc 75-80

Opens and then compares execution plans whose queryID is 73 from database qcd on server sysB, and whose queryID is in the range 75–80 from database qcd on server sysA using CLIv2 connectivity. In this example, plan with queryID.

5

VEComp -vc -f ValidVECfile1.vec 
-f ValidVECfile2.vec 
-f ValidVECfile3.vec

Opens and then compares execution plans from files ValidVECfile1.vec, ValidVECfile2.vec and ValidVECfile3.vec. The first plan is the base plan.

6

VEComp -vc ValidVECfile1.vec ValidVECfile3.vec ValidVECfile3.vec

Opens and then compares execution plans from files ValidVECfile1.vec, ValidVECfile2.vec and ValidVECfile3.vec. The first plan is the base plan.

7

VEComp -vc -f ValidVECfile1.vec 
-l sysB\dbc\dbc -d qcd -rc 73

Opens and then compares plans from file ValidVECfile1.vec, the online execution plan having queryID 73 from database qcd on server SysB. The plan opened from the file ValidVECfile1.vec is the base plan.