Database Reference
In-Depth Information
more information on this
format.)
object TableSchema
of the results.
(See the Table resource
description in Chapter 5 for
more information.)
schema
number
Total number of bytes processed
in the query. This is the amount
that you will be billed for
running the query (or in the case
of a dry run, the amount that
you would have been billed).
totalBytesProcessed
number
The total number of rows in the
result table
totalRows
Here is an example Python command to send a simple query request with a
large timeout value:
>>>
response = service.jobs().query(
…
projectId=project_id
,
…
body={'query': 'SELECT 17', 'timeoutMs':
1000000}).execute()
>>>
pprint.pprint(response)
{u'cacheHit': True,
u'jobComplete': True,
u'jobReference': {u'jobId':
u'job_85QYWMD7jBuqPOtIEgk1BaheODE',
u'projectId': u'bigquery-e2e'},
u'kind': u'bigquery#queryResponse',
u'rows': [{u'f': [{u'v': u'17'}]}],
u'schema': {u'fields': [{u'mode': u'NULLABLE',
u'name': u'f0_',
u'type': u'INTEGER'}]},
u'totalBytesProcessed': u'0',
u'totalRows': u'1'}