Query Banding Teradata Database Feature - Parallel Transporter

Teradata Parallel Transporter Application Programming Interface

Product
Parallel Transporter
Release Number
15.10
Language
English (United States)
Last Update
2018-10-07
dita:id
B035-2516
lifecycle
previous
Product Category
Teradata Tools and Utilities

Query Banding Teradata Database Feature

Available with the V12.0 Teradata Database, the query banding feature provides a user-defined query band expression that is set for every SQL session connected by the Teradata PT driver. A query band expression is a set of name-value pairs that identify a query’s originating source. In the expression, each name-value pair is separated by a semicolon and the expression ends with a semicolon. The following is an example of a valid query band expression:

a=1;b=2;c=3;d=4;

If the TD_QUERY_BAND_SESS_INFO is set, the following request will be sent by every SQL session connected by the Teradata PT driver:

SET QUERY_BAND =’<User-Defined Query Band Expression>’ FOR SESSION;

Setting the TD_QUERY_BAND_SESS_INFO attribute in jobs running against non‑supported versions of the Teradata Database causes a non-fatal error. No error code is returned to the user during initiation and the job is allowed to proceed. The log table will not be dropped at the end of the job and the TD_Evt_ExitCode event returns a warning value of four instead of the normal success value of zero if queried. In this case, error information can be found in the trace file.