DIAGNOSTIC DUMP SAMPLES - Teradata Database

SQL Data Manipulation Language

Product
Teradata Database
Release Number
16.10
Published
June 2017
Language
English (United States)
Last Update
2018-04-25
dita:mapPath
psg1480972718197.ditamap
dita:ditavalPath
changebar_rev_16_10_exclude_audience_ie.ditaval
dita:id
B035-1146
lifecycle
previous
Product Category
Teradata® Database

Purpose

Extracts random AMP samples from a target system and writes the samples to SystemFE.Opt_RAS_Table on that system.

For more information about random AMP samples, see:

Required Privileges

You must have INSERT privileges on SystemFE.Opt_RAS_Table to dump random AMP samples.

Syntax



Syntax Elements

target_system_name
Name used to designate the target (production) system from which random AMP sample information is to be estimated. For information on object naming, see SQL Fundamentals .
target_system_name is not case sensitive and can be up to 63 characters in length.
Names that contain pad characters or nonstandard characters must be enclosed in APOSTROPHE (U+0020) characters.
The primary key for the sample row in the table SystemFE.Opt_RAS_Table is target_system_name + database_name + table_name.
database_name
Name of the database in which table_name is defined.
If the name contains pad characters or non-standard characters, it must be demarcated by APOSTROPHE characters.
table_name
Name of the table for which random AMP sample statistics emulation is to be performed.
If the name contains pad characters or non-standard characters, it must be demarcated by APOSTROPHE characters.

ANSI Compliance

DIAGNOSTIC DUMP SAMPLES is a Teradata extension to the ANSI SQL:2011 standard.

DIAGNOSTIC DUMP SAMPLES and Target Level Emulation

DIAGNOSTIC DUMP SAMPLES does not require Target Level Emulation to be enabled in order to extract target system random AMP samples.

Session Mode Restrictions

You cannot perform DIAGNOSTIC DUMP SAMPLES in ANSI session mode or within explicit transaction boundaries in Teradata session mode.

Example: Extract Random AMP Samples

Dump the random AMP statistical samples on the current system for the payroll table in the employee database to SystemFE.Opt_RAS_Table. In this example, production_1 is the current system.

     DIAGNOSTIC DUMP SAMPLES Production_1 TABLE Employee.Payroll;