16.20 - Request-pointer and the USING Row Descriptor - Teradata Tools and Utilities

Teradata® Call-Level Interface Version 2 Reference for Mainframe-Attached Systems

prodname
Teradata Tools and Utilities
vrm_release
16.20
created_date
September 2019
category
Programming Reference
featnum
B035-2417-108K

If a USING row descriptor is included in the Teradata SQL request, the USING row descriptor must be the very first clause in the request.

The USING row descriptor names and describes each field of the data pointed to by USING-data-pointer, in positional sequence.

Each field name may be referred to any number of times in any number of statements in that request, including the case of no references to that name. The maximum number of fields may be obtained using the DBCHQE SQL-limits query.

An example of a valid request follows:

USING x1 (INTEGER), x2 (CHAR (2) )
      SELECT * FROM t1 WHERE c1 = :x2;
      SELECT * FROM t2 WHERE c2 = :x2;

The USING row descriptor is also used for macro arguments, as in the following example:

USING x1 (INTEGER) EXEC MACRO (:x1);

For more information about the nature of the USING row descriptor and where it is placed in relation to other information, see SQL Fundamentals (B035-1141).