SQL Strings - Teradata Preprocessor2

Teradata® Preprocessor2 for Embedded SQL Programmer Guide

Product
Teradata Preprocessor2
Release Number
17.00
Published
June 2020
Language
English (United States)
Last Update
2020-06-19
dita:mapPath
whb1544831946911.ditamap
dita:ditavalPath
obe1474387269547.ditaval
dita:id
B035-2446
lifecycle
previous
Product Category
Teradata Tools and Utilities

Define the variable name used for a SQL string as either a character or varying character type. For details on declaring character field, see Host Variable Declaration.

PP2 expects a terminating null character (a ‘\0’) if a character string variable is used as a SQL string. The code is generated based on the presence of the ‘\0’ in the string.

The ‘\0’ is not used, however, when a varying character variable is used as a SQL string. Use of a character string variable as a SQL string is a PP2 extension over DB2 rules, although any DB2 conforming SQL string is valid.