INITIATE PARTITION ANALYSIS Examples | SQL Statements | Teradata Vantage - 17.05 - INITIATE PARTITION ANALYSIS Examples - Advanced SQL Engine - Teradata Database

Teradata Vantage™ - SQL Data Manipulation Language

Product
Advanced SQL Engine
Teradata Database
Release Number
17.05
Published
January 2021
Language
English (United States)
Last Update
2021-01-22
dita:mapPath
vnq1596660420420.ditamap
dita:ditavalPath
hoy1596145193032.ditaval

Example: Partition Analysis on All Tables

The following example considers partitioning expression recommendations for all tables in a workload; therefore, no ON clause specified:

     INITIATE PARTITION ANALYSIS
     FOR myworkload
     IN myqcd
     AS myppirecs;

Now you can examine the recommended partitioning expressions from this partition analysis using the following SELECT request:

     SELECT tablename, expressiontext
     FROM qcd.partitionrecommendations
     WHERE resultnametag = 'myppirecs';

Example: Partition Analysis on Specified Tables

The following example considers partitioning expression recommendations for specific tables within a workload; therefore, an ON clause is specified:

     INITIATE PARTITION ANALYSIS
     ON tab1, tab2
     FOR myworkload 
     IN myqcd
     AS myppitabrecs;

Example: Partition Analysis with a Time Limit

The following example places a 5 minute time limit on the partitioning expression analysis:

     INITIATE PARTITION ANALYSIS
     FOR myworkload
     IN myqcd
     AS myfastanalysis
     TIME LIMIT = 5;