v1

latestOpenAPI 3.0.0Creative Commons Attribution 3.02026-07-1342224376.9 KB
jobs

RPC to get the results of a query job. # IAM Permissions Requires the following IAM permission(s) to use this method: - bigquery.jobs.get on the job. - bigquery.tables.getData on the destination table. If the user matches the creator of the job, the following IAM permission(s) are required instead: - bigquery.jobs.create on the project. - bigquery.tables.getData on the destination table.

get/projects/{+projectId}/queries/{+jobId}

Path parameters

projectIdstring required

Required. Project ID of the query job.

jobIdstring required

Required. Job ID of the query job.

Query parameters

formatOptions.timestampOutputFormat'TIMESTAMP_OUTPUT_FORMAT_UNSPECIFIED' | 'FLOAT64' | 'INT64' | 'ISO8601_STRING'

Optional. The API output format for a timestamp. This offers more explicit control over the timestamp output format as compared to the existing use_int64_timestamp option.

formatOptions.useInt64Timestampboolean

Optional. Output timestamp as usec int64. Default is false.

locationstring

The geographic location of the job. You must specify the location to run the job for the following scenarios: * If the location to run a job is not in the us or the eu multi-regional location * If the job's location is in a single region (for example, us-central1) For more information, see how to specify locations.

maxResultsinteger

Maximum number of results to read.

pageTokenstring

Page token, returned by a previous call, to request the next page of results.

startIndexstring

Zero-based index of the starting row.

timeoutMsinteger

Optional: Specifies the maximum amount of time, in milliseconds, that the client is willing to wait for the query to complete. By default, this limit is 10 seconds (10,000 milliseconds). If the query is complete, the jobComplete field in the response is true. If the query has not yet completed, jobComplete is false. You can request a longer timeout period in the timeoutMs field. However, the call is not guaranteed to wait for the specified timeout; it typically returns after around 200 seconds (200,000 milliseconds), even if the query is not complete. If jobComplete is false, you can continue to wait for the query to complete by calling the getQueryResults method until the jobComplete field in the getQueryResults response is true.

Response

Successful response