Documentation

Google_Service_Bigquery_Resource_Jobs extends Google_Service_Resource
in package

The "jobs" collection of methods.

Typical usage is: $bigqueryService = new Google_Service_Bigquery(...); $jobs = $bigqueryService->jobs;

Table of Contents

$client  : Google_Client
$methods  : array<string|int, mixed>
$resourceName  : string
$rootUrl  : string
$serviceName  : string
$servicePath  : string
$stackParameters  : mixed
__construct()  : mixed
call()  : Google_Http_Request|expectedClass
TODO: This function needs simplifying.
cancel()  : Google_Service_Bigquery_JobCancelResponse
Requests that a job be cancelled. This call will return immediately, and the client will need to poll for the job status to see if the cancel completed successfully. Cancelled jobs may still incur costs. (jobs.cancel)
createRequestUri()  : string
Parse/expand request parameters and create a fully qualified request uri.
get()  : Google_Service_Bigquery_Job
Returns information about a specific job. Job information is available for a six month period after creation. Requires that you're the person who ran the job, or have the Is Owner project role. (jobs.get)
getQueryResults()  : Google_Service_Bigquery_GetQueryResultsResponse
Retrieves the results of a query job. (jobs.getQueryResults)
insert()  : Google_Service_Bigquery_Job
Starts a new asynchronous job. Requires the Can View project role.
listJobs()  : Google_Service_Bigquery_JobList
Lists all jobs that you started in the specified project. Job information is available for a six month period after creation. The job list is sorted in reverse chronological order, by job creation time. Requires the Can View project role, or the Is Owner project role if you set the allUsers property.
query()  : Google_Service_Bigquery_QueryResponse
Runs a BigQuery SQL query synchronously and returns query results if the query completes within a specified timeout. (jobs.query)
convertToArrayAndStripNulls()  : mixed

Properties

$methods

private array<string|int, mixed> $methods

$resourceName

private string $resourceName

$serviceName

private string $serviceName

$servicePath

private string $servicePath

$stackParameters

private mixed $stackParameters = array('alt' => array('type' => 'string', 'location' => 'query'), 'fields' => array('type' => 'string', 'location' => 'query'), 'trace' => array('type' => 'string', 'location' => 'query'), 'userIp' => array('type' => 'string', 'location' => 'query'), 'quotaUser' => array('type' => 'string', 'location' => 'query'), 'data' => array('type' => 'string', 'location' => 'body'), 'mimeType' => array('type' => 'string', 'location' => 'header'), 'uploadType' => array('type' => 'string', 'location' => 'query'), 'mediaUpload' => array('type' => 'complex', 'location' => 'query'), 'prettyPrint' => array('type' => 'string', 'location' => 'query'))

Methods

__construct()

public __construct(mixed $service, mixed $serviceName, mixed $resourceName, mixed $resource) : mixed
Parameters
$service : mixed
$serviceName : mixed
$resourceName : mixed
$resource : mixed
Return values
mixed

call()

TODO: This function needs simplifying.

public call( $name,  $arguments[,  $expectedClass = null ]) : Google_Http_Request|expectedClass
Parameters
$name :
$arguments :
$expectedClass : = null
  • optional, the expected class name
Tags
throws
Google_Exception
Return values
Google_Http_Request|expectedClass

cancel()

Requests that a job be cancelled. This call will return immediately, and the client will need to poll for the job status to see if the cancel completed successfully. Cancelled jobs may still incur costs. (jobs.cancel)

public cancel(string $projectId, string $jobId[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Bigquery_JobCancelResponse
Parameters
$projectId : string

[Required] Project ID of the job to cancel

$jobId : string

[Required] Job ID of the job to cancel

$optParams : array<string|int, mixed> = array()

Optional parameters.

Tags
opt_param

string location The geographic location of the job. Required except for US and EU. See details at https://cloud.google.com/bigquery/docs/locations#specifying_your_location.

Return values
Google_Service_Bigquery_JobCancelResponse

createRequestUri()

Parse/expand request parameters and create a fully qualified request uri.

public createRequestUri(string $restPath, array<string|int, mixed> $params) : string
Parameters
$restPath : string
$params : array<string|int, mixed>
Tags
static
Return values
string

$requestUrl

get()

Returns information about a specific job. Job information is available for a six month period after creation. Requires that you're the person who ran the job, or have the Is Owner project role. (jobs.get)

public get(string $projectId, string $jobId[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Bigquery_Job
Parameters
$projectId : string

[Required] Project ID of the requested job

$jobId : string

[Required] Job ID of the requested job

$optParams : array<string|int, mixed> = array()

Optional parameters.

Tags
opt_param

string location The geographic location of the job. Required except for US and EU. See details at https://cloud.google.com/bigquery/docs/locations#specifying_your_location.

Return values
Google_Service_Bigquery_Job

getQueryResults()

Retrieves the results of a query job. (jobs.getQueryResults)

public getQueryResults(string $projectId, string $jobId[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Bigquery_GetQueryResultsResponse
Parameters
$projectId : string

[Required] Project ID of the query job

$jobId : string

[Required] Job ID of the query job

$optParams : array<string|int, mixed> = array()

Optional parameters.

Tags
opt_param

string maxResults Maximum number of results to read

opt_param

string startIndex Zero-based index of the starting row

opt_param

string location The geographic location where the job should run. Required except for US and EU. See details at https://cloud.google.com/bigquery/docs/locations#specifying_your_location.

opt_param

string timeoutMs How long to wait for the query to complete, in milliseconds, before returning. Default is 10 seconds. If the timeout passes before the job completes, the 'jobComplete' field in the response will be false

opt_param

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

Return values
Google_Service_Bigquery_GetQueryResultsResponse

insert()

Starts a new asynchronous job. Requires the Can View project role.

public insert(string $projectId, Google_Service_Bigquery_Job $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Bigquery_Job

(jobs.insert)

Parameters
$projectId : string

Project ID of the project that will be billed for the job

$postBody : Google_Service_Bigquery_Job
$optParams : array<string|int, mixed> = array()

Optional parameters.

Return values
Google_Service_Bigquery_Job

listJobs()

Lists all jobs that you started in the specified project. Job information is available for a six month period after creation. The job list is sorted in reverse chronological order, by job creation time. Requires the Can View project role, or the Is Owner project role if you set the allUsers property.

public listJobs(string $projectId[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Bigquery_JobList

(jobs.listJobs)

Parameters
$projectId : string

Project ID of the jobs to list

$optParams : array<string|int, mixed> = array()

Optional parameters.

Tags
opt_param

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

opt_param

string projection Restrict information returned to a set of selected fields

opt_param

string minCreationTime Min value for job creation time, in milliseconds since the POSIX epoch. If set, only jobs created after or at this timestamp are returned

opt_param

string maxResults Maximum number of results to return

opt_param

string stateFilter Filter for job state

opt_param

string parentJobId If set, retrieves only jobs whose parent is this job. Otherwise, retrieves only jobs which have no parent

opt_param

bool allUsers Whether to display jobs owned by all users in the project. Default false

opt_param

string maxCreationTime Max value for job creation time, in milliseconds since the POSIX epoch. If set, only jobs created before or at this timestamp are returned

Return values
Google_Service_Bigquery_JobList

query()

Runs a BigQuery SQL query synchronously and returns query results if the query completes within a specified timeout. (jobs.query)

public query(string $projectId, Google_Service_Bigquery_QueryRequest $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_Bigquery_QueryResponse
Parameters
$projectId : string

Project ID of the project billed for the query

$postBody : Google_Service_Bigquery_QueryRequest
$optParams : array<string|int, mixed> = array()

Optional parameters.

Return values
Google_Service_Bigquery_QueryResponse

convertToArrayAndStripNulls()

protected convertToArrayAndStripNulls(mixed $o) : mixed
Parameters
$o : mixed
Return values
mixed

Search results