Request Body | Teradata Query Service - Request Body - Teradata Query Service

Teradata® Query Service Installation, Configuration, and Usage Guide for Customers - 4.01.03.01, 4.01.07.00

Deployment
VantageCloud
VantageCore
Edition
Enterprise
IntelliFlex
VMware
Product
Teradata Query Service
Release Number
4.01.03.01, 4.01.07.00
Published
September 2023
Language
English (United States)
Last Update
2024-02-16
dita:mapPath
qla1666844235399.ditamap
dita:ditavalPath
ft:empty
dita:id
enn1467244092237
Product Category
Analytical Ecosystem
The request body of a SQL request is a JSON object. The only mandatory field is query; however, you can use the optional fields to control how the request is submitted and how the results are returned.
Name Type Description Default Value Required
query String One or more SQL statements to run separated by a semicolon.

The SQL statements can be parameterized by including question marks in place of SQL literals. For example, INSERT INTO mytable VALUES (?, ?, ?)

- Yes
params Array Array of arrays containing parameters to the SQL statement.

If more than one array exists, the statement is run multiple times, each time with the next array of parameters in the array.

- No
outParams Array Array of names of output parameters for a stored procedure. - No
batch Boolean If the statements are run using JDBC batch processing, set to true, else false. false No
session Long Session ID generated by the service. If the session is already in use, the request is queued. - No

Uses implicit session when not specified.

queryBands Object SESSION query bands to append prior to running the query. For example, { "queryBand1":"value1", "queryBand2":"value2" } - No
queueTimeout Integer Number of seconds the request waits in the queue before timing out. A zero value indicates that the request is not queued, and returns an error. no timeout No
queryTimeout Integer Number of seconds the client waits for the query to complete before timing out. For example, see JDBC Statement.setQueryTimeout() no timeout No
clientId String Unique ID specified by the client for later lookup of the state of the query. - No
rowOffset Integer Number of rows to discard at the beginning of the result set. Used when implementing paging. 0 No
rowLimit Integer Number of rows to limit the response to. A value of 0 disables the limit. 1000 No
format String Format to return the data.
The format can be one of the following:
  • "object": Data is returned as an array of JSON objects.
  • "array": Data is returned as an array of JSON arrays.
  • "csv": Data is returned as comma-separated values. The format effects the results section in the JSON response.
object No
includeColumns Boolean Indicates whether to include the column metadata in the response, such as the column names and types. Columns are included in the CSV output if the request format is "csv." false No