How to read syntax diagrams

Use the following description to read the syntax diagrams in this information. Link to detail.

  • Read the syntax diagrams from left to right, from top to bottom, following the path of the line.

    The ►►─── symbol indicates the beginning of a syntax diagram.

    The ───► symbol indicates that the syntax diagram is continued on the next line.

    The ►─── symbol indicates that the syntax diagram is continued from the previous line.

    The ───►◄ symbol indicates the end of a syntax diagram.

    Diagrams of syntactical units other than complete statements start with the ►─── symbol and end with the ───► symbol.

  • Required items appear on the horizontal line (the main path):

    Read syntax diagramSkip visual syntax diagramrequired_item
  • Optional items appear below the main path:

    Read syntax diagramSkip visual syntax diagramrequired_itemoptional_item
  • If you can choose from two or more items, they appear vertically, in a stack. If you must choose one of the items, one item of the stack appears on the main path:

    Read syntax diagramSkip visual syntax diagramrequired_itemrequired_choice1required_choice2

    If choosing one of the items is optional, the entire stack appears below the main path:

    Read syntax diagramSkip visual syntax diagramrequired_itemoptional_choice1optional_choice2

    If one of the items is the default, it appears above the main path and the remaining choices are shown below:

    Read syntax diagramSkip visual syntax diagramrequired_itemdefault_choiceoptional_choiceoptional_choice
  • An arrow returning to the left, above the main line, indicates an item that can be repeated:

    Read syntax diagramSkip visual syntax diagramrequired_itemrepeatable_item

    If the repeat arrow contains a comma, you must separate repeated items with a comma:

    Read syntax diagramSkip visual syntax diagramrequired_item,repeatable_item
  • Keywords appear in uppercase (for example, FROM). They must be spelled exactly as shown. Variables appear in lowercase italics (for example, column-name). They represent user-supplied names or values.
  • If punctuation marks, parentheses, arithmetic operators, or other such symbols are shown, you must enter them as part of the syntax.