15.10 - Continuation for SQL Statements - Preprocessor2 for Embedded SQL

Teradata Preprocessor2 for Embedded SQL Programmer Guide

prodname
Preprocessor2 for Embedded SQL
vrm_release
15.10
category
Programming Reference
featnum
B035-2446-035K

Line continuation rules for a SQL statement within EXEC SQL blocks are the same as C continuation rules, with the following exceptions:

  • The EXEC SQL prefix, including the FOR clause, must be specified on one line.
  • Strings within a SQL statement in Teradata mode cannot be continued with the backslash character.
  • All characters, including blanks, from the beginning string delimiter to the ending string delimiter, form the string.

    If the ending string delimiter is not found on the current line, all characters up to the right margin are considered part of the string.

    On the next line, all characters beginning in the left margin and continuing to the ending string delimiter are part of the string.

    If no blanks are required, specify the string all the way to the right margin (column 72 or 80, depending on the MARGINS PP2 option), and immediately resume the left margin at (column 1) of the next line.

    Strings in ANSI compatible mode can be continued with the backslash character. The backslash is not included as part of the string.