Saving an Execution Plan - Visual Explain

Teradata Visual Explain User Guide

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

One or more execution plans can be saved to a file (.vec). Saving an execution plan creates what is referred to as an offline plan. Optionally, the corresponding visual plan, Explain text, statement text, or tool tips can be saved.

When saving the plan as a file, a file name can be entered or automatically generated. To generate a file name automatically, one or more parameters must be selected. The parameters form the foundation of the file name. For example, selecting the USER and SERVER parameters results in a plan saved as john_server1.vec. (See “To save an execution plan” on page 142, step 5, for more information.)

Before saving, open one or more execution plans.

1 Click .

The Save As dialog box appears.

2 Under Save Options, do one of the following:

  • Select one or more check boxes to define the type of information saved.
  • Select the All check box (default setting) to save all options.
  •  

    Check Box

    Description

    All

    Saves the visual plan, Explain text, statement text, and tool tips in separate files.

    Explain text

    Saves the Explain text of the plan in a text file (.txt).

    Tool tips

    Saves the tool tips that are displayed in the visual plan in a text file (.txt).

    Visual plan

    Saves the plan details into a binary file (.vec).

    Also saves the Explain text, statement text, and tool tips in the .vec file so they are available when the offline plan is opened.

    Statement text

    Saves the query text of the plan in a text file (.sql).

    3 [Optional] Under Multiple Plans, click Select plans to select open plans to save.

    4 [Optional] Under Multiple Plans, select check boxes to further define how the selected plans are saved.

     

    Check Box

    Description

    Save multiple plans

    Save all plans selected in step 3.

    Note: If the check box is clear, only the active plan is saved. Click Select plans to specify plans to save.

    Save all plans to single file

    Save all plans selected in step 3 to a single file. The file name must be specified in the File Name box.

    Note: Automatic file‑name generation is unavailable when this check box is selected, and the File Name Preview box becomes the File Name box. If the Save all plans to single file check box is clear, plans are saved to separate files.

    5 Under File Name Format, do one of the following:

  • To create the file name manually:
  • i Clear the Generate file name(s) automatically check box.

    i Clear the Generate file name(s) automatically check box.

    ii Type a file name in the File Name box.

  • To generate the file name automatically:
  • i Select the Generate file name(s) automatically check box (default setting).

    i Select the Generate file name(s) automatically check box (default setting).

    ii In the Available box, select one or more parameters.

    iii Click Add.

     

    Parameter

    Information Included in File Name

    USER

    Name of the user who captured the plan

    SERVER

    Name of the server where the plan was captured

    QUERYTAG

    Query tag for the plan

    QCD

    QCD for the plan

    QUERYID

    Query ID for the plan

    TIMESTAMP

    Date and time the file is saved

    Note: The format is day, month, hour, minute, second (ddmmm‑hh‑mm‑ss).

    Selected parameter names appear in the File Name Preview box. Parameter names appear in the order in which they were selected and are separated by the _ symbol. For example, if the first parameter selected and moved to the Selected box is SERVER and the second parameter is USER, the file name is <SERVER>_<USER>.

    6 [Optional] To remove parameters so they are not included in the file name:

    a In the Selected box, select the parameter to remove.

    b Click Remove.

    7 [Optional] To change the default location at which the file is saved, do one of the following:

  • Type a location in the Path box.
  • Click to browse for a folder.
  • 8 Click Save to save the execution plans.