15.10 - GetQueryBandSP - Teradata Database

Teradata Database Application Programming Reference

prodname
Teradata Database
vrm_release
15.10
category
Programming Reference
featnum
B035-1090-151K

Returns the concatenated query band for the current transaction and session.

REPLACE PROCEDURE SYSLIB.GetQueryBandSP
   (OUT queryband VARCHAR(6159) CHARACTER SET UNICODE
   )
            .
            .
            .
;

The GetQueryBandSP procedure retrieves the query band directly from memory.

This procedure is created in the SYSLIB database by the DEM DIP script. EXECUTE privileges are granted to PUBLIC by default. For more information, see “Requirements for Using the API” on page 19.

For information on setting the query band for a session or transaction, see SET QUERY_BAND in SQL Data Definition Language.

The query band output parameter contains the concatenated transaction, session, and profile query bands.

CALL SYSLIB.GetQueryBandSP(qb);
 
 *** Procedure has been executed. 
 *** Total elapsed time was 1 second.
 
queryband
-----------------------------------------------------------------
=T> aa=123;bb=yxs;cc=mmmmm; =S> a=1;b=2;c=3;d=4;