Use of Query Bands | SET QUERY_BAND | Teradata Vantage - Query Bands and External Routines - Analytics Database - Teradata Vantage

SQL Data Definition Language Detailed Topics

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Analytics Database
Teradata Vantage
Release Number
17.20
Published
June 2022
Language
English (United States)
Last Update
2023-07-11
dita:mapPath
vuk1628111288877.ditamap
dita:ditavalPath
qkf1628213546010.ditaval
dita:id
B035-1184
lifecycle
latest
Product Category
Teradata Vantage™

External routines can access the query band information for both sessions and transactions. External routine is the generic term to describe external procedures, UDFs, and user-defined methods.

For example, SQL procedures can make SQL requests to set the query band of the transaction using a SET QUERY_BAND request. An SQL procedure can also retrieve the current query band using the QUERY_BAND built-in function.

An external procedure can set the transaction query band by calling an SQL procedure. You can also use an FNC call to retrieve the query band or to get the value of a name within it.

Note that there is no FNC interface to set a query band (see Teradata Vantage™ - SQL External Routine Programming, B035-1147 for details).