How to Read Syntax | Teradata Vantage - How to Read Syntax - Advanced SQL Engine - Teradata Database

SQL Data Definition Language Syntax and Examples

Product
Advanced SQL Engine
Teradata Database
Release Number
17.00
Published
September 2020
Language
English (United States)
Last Update
2021-01-23
dita:mapPath
wgr1555383704548.ditamap
dita:ditavalPath
lze1555437562152.ditaval
dita:id
B035-1144
lifecycle
previous
Product Category
Teradata Vantage™

This document uses the following syntax conventions.

Syntax Convention Meaning
KEYWORD
Keyword. Spell exactly as shown.

Many environments are case-insensitive. Syntax shows keywords in uppercase unless operating system restrictions require them to be lowercase or mixed-case.

variable
Variable. Replace with actual value.
number
String of one or more digits. Do not use commas in numbers with more than three digits.

Example: 10045

[ x ]
x is optional.
[ x | y ]
You can specify x, y, or nothing.
{ x | y }
You must specify either x or y.
x [...]
You can repeat x, separating occurrences with spaces.

Example: x x x

See note after table.

x [,...]
You can repeat x, separating occurrences with commas.

Example: x, x, x

See note after table.

x [delimiter...]
You can repeat x, separating occurrences with specified delimiter.
Examples:
  • If delimiter is semicolon:

    x; x; x

  • If delimiter is {,|OR}, you can do either of the following:
    • x, x, x
    • x OR x OR x

See note after table.

You can repeat only the immediately preceding item. For example, if the syntax is:
KEYWORD x [...]

You can repeat x. Do not repeat KEYWORD.

If there is no white space between x and the delimiter, the repeatable item is x and the delimiter. For example, if the syntax is:

[ x, [...] ] y
  • You can omit x: y
  • You can specify x once: x, y
  • You can repeat x and the delimiter: x, x, x, y