google.cloud.bigquery.routine.RoutineReference#

Methods

from_api_repr(resource)

Factory: construct a routine reference given its API representation.

from_string(routine_id[, default_project])

Factory: construct a routine reference from routine ID string.

to_api_repr()

Construct the API resource representation of this routine reference.

Attributes

dataset_id

ID of dataset containing the routine.

path

URL path for the routine’s APIs.

project

ID of the project containing the routine.

routine_id

The routine ID.


class google.cloud.bigquery.routine.RoutineReference[source]#

Bases: object

A pointer to a routine.

See https://cloud.google.com/bigquery/docs/reference/rest/v2/routines

property dataset_id#

ID of dataset containing the routine.

Type

str

classmethod from_api_repr(resource)[source]#

Factory: construct a routine reference given its API representation.

Parameters

resource (Dict[str, object]) – Routine reference representation returned from the API.

Returns

Routine reference parsed from resource.

Return type

google.cloud.bigquery.routine.RoutineReference

classmethod from_string(routine_id, default_project=None)[source]#

Factory: construct a routine reference from routine ID string.

Parameters
  • routine_id (str) – A routine ID in standard SQL format. If default_project is not specified, this must included a project ID, dataset ID, and routine ID, each separated by ..

  • default_project (str) – Optional. The project ID to use when routine_id does not include a project ID.

Returns

Routine reference parsed from routine_id.

Return type

google.cloud.bigquery.routine.RoutineReference

Raises

ValueError – If routine_id is not a fully-qualified routine ID in standard SQL format.

property path#

URL path for the routine’s APIs.

Type

str

property project#

ID of the project containing the routine.

Type

str

property routine_id#

The routine ID.

Type

str

to_api_repr()[source]#

Construct the API resource representation of this routine reference.

Returns

Routine reference represented as an API resource.

Return type

Dict[str, object]