Class: Google::Apis::BigqueryV2::BigqueryService
- Inherits:
-
Core::BaseService
- Object
- Core::BaseService
- Google::Apis::BigqueryV2::BigqueryService
- Defined in:
- lib/google/apis/bigquery_v2/service.rb
Overview
BigQuery API
A data platform for customers to create, manage, share and query data.
Instance Attribute Summary collapse
-
#key ⇒ String
API key.
-
#quota_user ⇒ String
An opaque string that represents a user for quota purposes.
-
#user_ip ⇒ String
Deprecated.
Instance Method Summary collapse
-
#cancel_job(project_id, job_id, location: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::CancelJobResponse
Requests that a job be cancelled.
-
#delete_dataset(project_id, dataset_id, delete_contents: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... }
Deletes the dataset specified by the datasetId value.
-
#delete_job(project_id, job_id, location: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... }
Requests the deletion of the metadata of a job.
-
#delete_model(project_id, dataset_id, model_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... }
Deletes the model specified by modelId from the dataset.
-
#delete_routine(project_id, dataset_id, routine_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... }
Deletes the routine specified by routineId from the dataset.
-
#delete_table(project_id, dataset_id, table_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... }
Deletes the table specified by tableId from the dataset.
-
#get_dataset(project_id, dataset_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Dataset
Returns the dataset specified by datasetID.
-
#get_job(project_id, job_id, location: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Job
Returns information about a specific job.
-
#get_job_query_results(project_id, job_id, location: nil, max_results: nil, page_token: nil, start_index: nil, timeout_ms: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::GetQueryResultsResponse
Retrieves the results of a query job.
-
#get_model(project_id, dataset_id, model_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Model
Gets the specified model resource by model ID.
-
#get_project_service_account(project_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::GetServiceAccountResponse
Returns the email address of the service account for your project used for interactions with Google Cloud KMS.
-
#get_routine(project_id, dataset_id, routine_id, read_mask: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Routine
Gets the specified routine resource by routine ID.
-
#get_row_access_policy_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Policy
Gets the access control policy for a resource.
-
#get_table(project_id, dataset_id, table_id, selected_fields: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Table
Gets the specified table resource by table ID.
-
#get_table_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Policy
Gets the access control policy for a resource.
-
#initialize ⇒ BigqueryService
constructor
A new instance of BigqueryService.
-
#insert_all_table_data(project_id, dataset_id, table_id, insert_all_table_data_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::InsertAllTableDataResponse
Streams data into BigQuery one record at a time without needing to run a load job.
-
#insert_dataset(project_id, dataset_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Dataset
Creates a new empty dataset.
-
#insert_job(project_id, job_object = nil, fields: nil, quota_user: nil, user_ip: nil, upload_source: nil, content_type: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Job
Starts a new asynchronous job.
-
#insert_routine(project_id, dataset_id, routine_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Routine
Creates a new routine in the dataset.
-
#insert_table(project_id, dataset_id, table_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Table
Creates a new, empty table in the dataset.
-
#list_datasets(project_id, all: nil, filter: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::DatasetList
Lists all datasets in the specified project to which you have been granted the READER dataset role.
-
#list_jobs(project_id, all_users: nil, max_creation_time: nil, max_results: nil, min_creation_time: nil, page_token: nil, parent_job_id: nil, projection: nil, state_filter: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::JobList
Lists all jobs that you started in the specified project.
-
#list_models(project_id, dataset_id, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::ListModelsResponse
Lists all models in the specified dataset.
-
#list_projects(max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::ProjectList
Lists all projects to which you have been granted any project role.
-
#list_routines(project_id, dataset_id, filter: nil, max_results: nil, page_token: nil, read_mask: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::ListRoutinesResponse
Lists all routines in the specified dataset.
-
#list_row_access_policies(project_id, dataset_id, table_id, page_size: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::ListRowAccessPoliciesResponse
Lists all row access policies on the specified table.
-
#list_table_data(project_id, dataset_id, table_id, max_results: nil, page_token: nil, selected_fields: nil, start_index: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::TableDataList
Retrieves table data from a specified set of rows.
-
#list_tables(project_id, dataset_id, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::TableList
Lists all tables in the specified dataset.
-
#patch_dataset(project_id, dataset_id, dataset_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Dataset
Updates information in an existing dataset.
-
#patch_model(project_id, dataset_id, model_id, model_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Model
Patch specific fields in the specified model.
-
#patch_table(project_id, dataset_id, table_id, table_object = nil, autodetect_schema: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Table
Updates information in an existing table.
-
#query_job(project_id, query_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::QueryResponse
Runs a BigQuery SQL query synchronously and returns query results if the query completes within a specified timeout.
-
#set_row_access_policy_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Policy
Sets the access control policy on the specified resource.
-
#set_table_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Policy
Sets the access control policy on the specified resource.
-
#test_row_access_policy_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::TestIamPermissionsResponse
Returns permissions that a caller has on the specified resource.
-
#test_table_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::TestIamPermissionsResponse
Returns permissions that a caller has on the specified resource.
-
#update_dataset(project_id, dataset_id, dataset_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Dataset
Updates information in an existing dataset.
-
#update_routine(project_id, dataset_id, routine_id, routine_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Routine
Updates information in an existing routine.
-
#update_table(project_id, dataset_id, table_id, table_object = nil, autodetect_schema: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Table
Updates information in an existing table.
Constructor Details
#initialize ⇒ BigqueryService
Returns a new instance of BigqueryService.
49 50 51 52 53 54 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 49 def initialize super('https://bigquery.googleapis.com/', 'bigquery/v2/', client_name: 'google-apis-bigquery_v2', client_version: Google::Apis::BigqueryV2::GEM_VERSION) @batch_path = 'batch/bigquery/v2' end |
Instance Attribute Details
#key ⇒ String
Returns API key. Your API key identifies your project and provides you with API access, quota, and reports. Required unless you provide an OAuth 2.0 token.
38 39 40 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 38 def key @key end |
#quota_user ⇒ String
Returns An opaque string that represents a user for quota purposes. Must not exceed 40 characters.
43 44 45 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 43 def quota_user @quota_user end |
#user_ip ⇒ String
Returns Deprecated. Please use quotaUser instead.
47 48 49 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 47 def user_ip @user_ip end |
Instance Method Details
#cancel_job(project_id, job_id, location: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::CancelJobResponse
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.
330 331 332 333 334 335 336 337 338 339 340 341 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 330 def cancel_job(project_id, job_id, location: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:post, 'projects/{projectId}/jobs/{jobId}/cancel', ) command.response_representation = Google::Apis::BigqueryV2::CancelJobResponse::Representation command.response_class = Google::Apis::BigqueryV2::CancelJobResponse command.params['projectId'] = project_id unless project_id.nil? command.params['jobId'] = job_id unless job_id.nil? command.query['location'] = location unless location.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#delete_dataset(project_id, dataset_id, delete_contents: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... }
This method returns an undefined value.
Deletes the dataset specified by the datasetId value. Before you can delete a dataset, you must delete all its tables, either manually or by specifying deleteContents. Immediately after deletion, you can create another dataset with the same name.
86 87 88 89 90 91 92 93 94 95 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 86 def delete_dataset(project_id, dataset_id, delete_contents: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:delete, 'projects/{projectId}/datasets/{datasetId}', ) command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.query['deleteContents'] = delete_contents unless delete_contents.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#delete_job(project_id, job_id, location: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... }
This method returns an undefined value.
Requests the deletion of the metadata of a job. This call returns when the job' s metadata is deleted.
373 374 375 376 377 378 379 380 381 382 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 373 def delete_job(project_id, job_id, location: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:delete, 'projects/{+projectId}/jobs/{+jobId}/delete', ) command.params['projectId'] = project_id unless project_id.nil? command.params['jobId'] = job_id unless job_id.nil? command.query['location'] = location unless location.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#delete_model(project_id, dataset_id, model_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... }
This method returns an undefined value.
Deletes the model specified by modelId from the dataset.
653 654 655 656 657 658 659 660 661 662 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 653 def delete_model(project_id, dataset_id, model_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:delete, 'projects/{+projectId}/datasets/{+datasetId}/models/{+modelId}', ) command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.params['modelId'] = model_id unless model_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#delete_routine(project_id, dataset_id, routine_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... }
This method returns an undefined value.
Deletes the routine specified by routineId from the dataset.
886 887 888 889 890 891 892 893 894 895 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 886 def delete_routine(project_id, dataset_id, routine_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:delete, 'projects/{+projectId}/datasets/{+datasetId}/routines/{+routineId}', ) command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.params['routineId'] = routine_id unless routine_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#delete_table(project_id, dataset_id, table_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... }
This method returns an undefined value.
Deletes the table specified by tableId from the dataset. If the table contains data, all the data will be deleted.
1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1366 def delete_table(project_id, dataset_id, table_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:delete, 'projects/{projectId}/datasets/{datasetId}/tables/{tableId}', ) command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.params['tableId'] = table_id unless table_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#get_dataset(project_id, dataset_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Dataset
Returns the dataset specified by datasetID.
121 122 123 124 125 126 127 128 129 130 131 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 121 def get_dataset(project_id, dataset_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects/{projectId}/datasets/{datasetId}', ) command.response_representation = Google::Apis::BigqueryV2::Dataset::Representation command.response_class = Google::Apis::BigqueryV2::Dataset command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#get_job(project_id, job_id, location: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::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.
413 414 415 416 417 418 419 420 421 422 423 424 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 413 def get_job(project_id, job_id, location: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects/{projectId}/jobs/{jobId}', ) command.response_representation = Google::Apis::BigqueryV2::Job::Representation command.response_class = Google::Apis::BigqueryV2::Job command.params['projectId'] = project_id unless project_id.nil? command.params['jobId'] = job_id unless job_id.nil? command.query['location'] = location unless location.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#get_job_query_results(project_id, job_id, location: nil, max_results: nil, page_token: nil, start_index: nil, timeout_ms: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::GetQueryResultsResponse
Retrieves the results of a query job.
464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 464 def get_job_query_results(project_id, job_id, location: nil, max_results: nil, page_token: nil, start_index: nil, timeout_ms: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects/{projectId}/queries/{jobId}', ) command.response_representation = Google::Apis::BigqueryV2::GetQueryResultsResponse::Representation command.response_class = Google::Apis::BigqueryV2::GetQueryResultsResponse command.params['projectId'] = project_id unless project_id.nil? command.params['jobId'] = job_id unless job_id.nil? command.query['location'] = location unless location.nil? command.query['maxResults'] = max_results unless max_results.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['startIndex'] = start_index unless start_index.nil? command.query['timeoutMs'] = timeout_ms unless timeout_ms.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#get_model(project_id, dataset_id, model_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Model
Gets the specified model resource by model ID.
690 691 692 693 694 695 696 697 698 699 700 701 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 690 def get_model(project_id, dataset_id, model_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects/{+projectId}/datasets/{+datasetId}/models/{+modelId}', ) command.response_representation = Google::Apis::BigqueryV2::Model::Representation command.response_class = Google::Apis::BigqueryV2::Model command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.params['modelId'] = model_id unless model_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#get_project_service_account(project_id, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::GetServiceAccountResponse
Returns the email address of the service account for your project used for interactions with Google Cloud KMS.
813 814 815 816 817 818 819 820 821 822 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 813 def get_project_service_account(project_id, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects/{projectId}/serviceAccount', ) command.response_representation = Google::Apis::BigqueryV2::GetServiceAccountResponse::Representation command.response_class = Google::Apis::BigqueryV2::GetServiceAccountResponse command.params['projectId'] = project_id unless project_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#get_routine(project_id, dataset_id, routine_id, read_mask: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Routine
Gets the specified routine resource by routine ID.
926 927 928 929 930 931 932 933 934 935 936 937 938 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 926 def get_routine(project_id, dataset_id, routine_id, read_mask: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects/{+projectId}/datasets/{+datasetId}/routines/{+routineId}', ) command.response_representation = Google::Apis::BigqueryV2::Routine::Representation command.response_class = Google::Apis::BigqueryV2::Routine command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.params['routineId'] = routine_id unless routine_id.nil? command.query['readMask'] = read_mask unless read_mask.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#get_row_access_policy_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Policy
Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.
1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1102 def get_row_access_policy_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:post, '{+resource}:getIamPolicy', ) command.request_representation = Google::Apis::BigqueryV2::GetIamPolicyRequest::Representation command.request_object = get_iam_policy_request_object command.response_representation = Google::Apis::BigqueryV2::Policy::Representation command.response_class = Google::Apis::BigqueryV2::Policy command.params['resource'] = resource unless resource.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#get_table(project_id, dataset_id, table_id, selected_fields: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Table
Gets the specified table resource by table ID. This method does not return the data in the table, it only returns the table resource, which describes the structure of this table.
1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1412 def get_table(project_id, dataset_id, table_id, selected_fields: nil, view: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects/{projectId}/datasets/{datasetId}/tables/{tableId}', ) command.response_representation = Google::Apis::BigqueryV2::Table::Representation command.response_class = Google::Apis::BigqueryV2::Table command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.params['tableId'] = table_id unless table_id.nil? command.query['selectedFields'] = selected_fields unless selected_fields.nil? command.query['view'] = view unless view.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#get_table_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Policy
Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.
1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1453 def get_table_iam_policy(resource, get_iam_policy_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:post, '{+resource}:getIamPolicy', ) command.request_representation = Google::Apis::BigqueryV2::GetIamPolicyRequest::Representation command.request_object = get_iam_policy_request_object command.response_representation = Google::Apis::BigqueryV2::Policy::Representation command.response_class = Google::Apis::BigqueryV2::Policy command.params['resource'] = resource unless resource.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#insert_all_table_data(project_id, dataset_id, table_id, insert_all_table_data_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::InsertAllTableDataResponse
Streams data into BigQuery one record at a time without needing to run a load job. Requires the WRITER dataset role.
1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1271 def insert_all_table_data(project_id, dataset_id, table_id, insert_all_table_data_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:post, 'projects/{projectId}/datasets/{datasetId}/tables/{tableId}/insertAll', ) command.request_representation = Google::Apis::BigqueryV2::InsertAllTableDataRequest::Representation command.request_object = insert_all_table_data_request_object command.response_representation = Google::Apis::BigqueryV2::InsertAllTableDataResponse::Representation command.response_class = Google::Apis::BigqueryV2::InsertAllTableDataResponse command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.params['tableId'] = table_id unless table_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#insert_dataset(project_id, dataset_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Dataset
Creates a new empty dataset.
156 157 158 159 160 161 162 163 164 165 166 167 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 156 def insert_dataset(project_id, dataset_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:post, 'projects/{projectId}/datasets', ) command.request_representation = Google::Apis::BigqueryV2::Dataset::Representation command.request_object = dataset_object command.response_representation = Google::Apis::BigqueryV2::Dataset::Representation command.response_class = Google::Apis::BigqueryV2::Dataset command.params['projectId'] = project_id unless project_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#insert_job(project_id, job_object = nil, fields: nil, quota_user: nil, user_ip: nil, upload_source: nil, content_type: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Job
Starts a new asynchronous job. Requires the Can View project role.
508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 508 def insert_job(project_id, job_object = nil, fields: nil, quota_user: nil, user_ip: nil, upload_source: nil, content_type: nil, options: nil, &block) if upload_source.nil? command = make_simple_command(:post, 'projects/{projectId}/jobs', ) else command = make_upload_command(:post, 'projects/{projectId}/jobs', ) command.upload_source = upload_source command.upload_content_type = content_type end command.request_representation = Google::Apis::BigqueryV2::Job::Representation command.request_object = job_object command.response_representation = Google::Apis::BigqueryV2::Job::Representation command.response_class = Google::Apis::BigqueryV2::Job command.params['projectId'] = project_id unless project_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#insert_routine(project_id, dataset_id, routine_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Routine
Creates a new routine in the dataset.
965 966 967 968 969 970 971 972 973 974 975 976 977 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 965 def insert_routine(project_id, dataset_id, routine_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:post, 'projects/{+projectId}/datasets/{+datasetId}/routines', ) command.request_representation = Google::Apis::BigqueryV2::Routine::Representation command.request_object = routine_object command.response_representation = Google::Apis::BigqueryV2::Routine::Representation command.response_class = Google::Apis::BigqueryV2::Routine command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#insert_table(project_id, dataset_id, table_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Table
Creates a new, empty table in the dataset.
1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1491 def insert_table(project_id, dataset_id, table_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:post, 'projects/{projectId}/datasets/{datasetId}/tables', ) command.request_representation = Google::Apis::BigqueryV2::Table::Representation command.request_object = table_object command.response_representation = Google::Apis::BigqueryV2::Table::Representation command.response_class = Google::Apis::BigqueryV2::Table command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#list_datasets(project_id, all: nil, filter: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::DatasetList
Lists all datasets in the specified project to which you have been granted the READER dataset role.
203 204 205 206 207 208 209 210 211 212 213 214 215 216 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 203 def list_datasets(project_id, all: nil, filter: nil, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects/{projectId}/datasets', ) command.response_representation = Google::Apis::BigqueryV2::DatasetList::Representation command.response_class = Google::Apis::BigqueryV2::DatasetList command.params['projectId'] = project_id unless project_id.nil? command.query['all'] = all unless all.nil? command.query['filter'] = filter unless filter.nil? command.query['maxResults'] = max_results unless max_results.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#list_jobs(project_id, all_users: nil, max_creation_time: nil, max_results: nil, min_creation_time: nil, page_token: nil, parent_job_id: nil, projection: nil, state_filter: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::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.
571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 571 def list_jobs(project_id, all_users: nil, max_creation_time: nil, max_results: nil, min_creation_time: nil, page_token: nil, parent_job_id: nil, projection: nil, state_filter: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects/{projectId}/jobs', ) command.response_representation = Google::Apis::BigqueryV2::JobList::Representation command.response_class = Google::Apis::BigqueryV2::JobList command.params['projectId'] = project_id unless project_id.nil? command.query['allUsers'] = all_users unless all_users.nil? command.query['maxCreationTime'] = max_creation_time unless max_creation_time.nil? command.query['maxResults'] = max_results unless max_results.nil? command.query['minCreationTime'] = min_creation_time unless min_creation_time.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['parentJobId'] = parent_job_id unless parent_job_id.nil? command.query['projection'] = projection unless projection.nil? command.query['stateFilter'] = state_filter unless state_filter.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#list_models(project_id, dataset_id, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::ListModelsResponse
Lists all models in the specified dataset. Requires the READER dataset role. After retrieving the list of models, you can get information about a particular model by calling the models.get method.
734 735 736 737 738 739 740 741 742 743 744 745 746 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 734 def list_models(project_id, dataset_id, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects/{+projectId}/datasets/{+datasetId}/models', ) command.response_representation = Google::Apis::BigqueryV2::ListModelsResponse::Representation command.response_class = Google::Apis::BigqueryV2::ListModelsResponse command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.query['maxResults'] = max_results unless max_results.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#list_projects(max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::ProjectList
Lists all projects to which you have been granted any project role.
848 849 850 851 852 853 854 855 856 857 858 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 848 def list_projects(max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects', ) command.response_representation = Google::Apis::BigqueryV2::ProjectList::Representation command.response_class = Google::Apis::BigqueryV2::ProjectList command.query['maxResults'] = max_results unless max_results.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#list_routines(project_id, dataset_id, filter: nil, max_results: nil, page_token: nil, read_mask: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::ListRoutinesResponse
Lists all routines in the specified dataset. Requires the READER dataset role.
1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1017 def list_routines(project_id, dataset_id, filter: nil, max_results: nil, page_token: nil, read_mask: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects/{+projectId}/datasets/{+datasetId}/routines', ) command.response_representation = Google::Apis::BigqueryV2::ListRoutinesResponse::Representation command.response_class = Google::Apis::BigqueryV2::ListRoutinesResponse command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.query['filter'] = filter unless filter.nil? command.query['maxResults'] = max_results unless max_results.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['readMask'] = read_mask unless read_mask.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#list_row_access_policies(project_id, dataset_id, table_id, page_size: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::ListRowAccessPoliciesResponse
Lists all row access policies on the specified table.
1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1146 def list_row_access_policies(project_id, dataset_id, table_id, page_size: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects/{+projectId}/datasets/{+datasetId}/tables/{+tableId}/rowAccessPolicies', ) command.response_representation = Google::Apis::BigqueryV2::ListRowAccessPoliciesResponse::Representation command.response_class = Google::Apis::BigqueryV2::ListRowAccessPoliciesResponse command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.params['tableId'] = table_id unless table_id.nil? command.query['pageSize'] = page_size unless page_size.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#list_table_data(project_id, dataset_id, table_id, max_results: nil, page_token: nil, selected_fields: nil, start_index: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::TableDataList
Retrieves table data from a specified set of rows. Requires the READER dataset role.
1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1322 def list_table_data(project_id, dataset_id, table_id, max_results: nil, page_token: nil, selected_fields: nil, start_index: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects/{projectId}/datasets/{datasetId}/tables/{tableId}/data', ) command.response_representation = Google::Apis::BigqueryV2::TableDataList::Representation command.response_class = Google::Apis::BigqueryV2::TableDataList command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.params['tableId'] = table_id unless table_id.nil? command.query['maxResults'] = max_results unless max_results.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['selectedFields'] = selected_fields unless selected_fields.nil? command.query['startIndex'] = start_index unless start_index.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#list_tables(project_id, dataset_id, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::TableList
Lists all tables in the specified dataset. Requires the READER dataset role.
1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1533 def list_tables(project_id, dataset_id, max_results: nil, page_token: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:get, 'projects/{projectId}/datasets/{datasetId}/tables', ) command.response_representation = Google::Apis::BigqueryV2::TableList::Representation command.response_class = Google::Apis::BigqueryV2::TableList command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.query['maxResults'] = max_results unless max_results.nil? command.query['pageToken'] = page_token unless page_token.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#patch_dataset(project_id, dataset_id, dataset_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Dataset
Updates information in an existing dataset. The update method replaces the entire dataset resource, whereas the patch method only replaces fields that are provided in the submitted dataset resource. This method supports patch semantics.
246 247 248 249 250 251 252 253 254 255 256 257 258 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 246 def patch_dataset(project_id, dataset_id, dataset_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:patch, 'projects/{projectId}/datasets/{datasetId}', ) command.request_representation = Google::Apis::BigqueryV2::Dataset::Representation command.request_object = dataset_object command.response_representation = Google::Apis::BigqueryV2::Dataset::Representation command.response_class = Google::Apis::BigqueryV2::Dataset command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#patch_model(project_id, dataset_id, model_id, model_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Model
Patch specific fields in the specified model.
775 776 777 778 779 780 781 782 783 784 785 786 787 788 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 775 def patch_model(project_id, dataset_id, model_id, model_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:patch, 'projects/{+projectId}/datasets/{+datasetId}/models/{+modelId}', ) command.request_representation = Google::Apis::BigqueryV2::Model::Representation command.request_object = model_object command.response_representation = Google::Apis::BigqueryV2::Model::Representation command.response_class = Google::Apis::BigqueryV2::Model command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.params['modelId'] = model_id unless model_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#patch_table(project_id, dataset_id, table_id, table_object = nil, autodetect_schema: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Table
Updates information in an existing table. The update method replaces the entire table resource, whereas the patch method only replaces fields that are provided in the submitted table resource. This method supports patch semantics.
1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1578 def patch_table(project_id, dataset_id, table_id, table_object = nil, autodetect_schema: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:patch, 'projects/{projectId}/datasets/{datasetId}/tables/{tableId}', ) command.request_representation = Google::Apis::BigqueryV2::Table::Representation command.request_object = table_object command.response_representation = Google::Apis::BigqueryV2::Table::Representation command.response_class = Google::Apis::BigqueryV2::Table command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.params['tableId'] = table_id unless table_id.nil? command.query['autodetect_schema'] = autodetect_schema unless autodetect_schema.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#query_job(project_id, query_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::QueryResponse
Runs a BigQuery SQL query synchronously and returns query results if the query completes within a specified timeout.
614 615 616 617 618 619 620 621 622 623 624 625 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 614 def query_job(project_id, query_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:post, 'projects/{projectId}/queries', ) command.request_representation = Google::Apis::BigqueryV2::QueryRequest::Representation command.request_object = query_request_object command.response_representation = Google::Apis::BigqueryV2::QueryResponse::Representation command.response_class = Google::Apis::BigqueryV2::QueryResponse command.params['projectId'] = project_id unless project_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#set_row_access_policy_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Policy
Sets the access control policy on the specified resource. Replaces any
existing policy. Can return NOT_FOUND
, INVALID_ARGUMENT
, and
PERMISSION_DENIED
errors.
1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1188 def set_row_access_policy_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:post, '{+resource}:setIamPolicy', ) command.request_representation = Google::Apis::BigqueryV2::SetIamPolicyRequest::Representation command.request_object = set_iam_policy_request_object command.response_representation = Google::Apis::BigqueryV2::Policy::Representation command.response_class = Google::Apis::BigqueryV2::Policy command.params['resource'] = resource unless resource.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#set_table_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Policy
Sets the access control policy on the specified resource. Replaces any
existing policy. Can return NOT_FOUND
, INVALID_ARGUMENT
, and
PERMISSION_DENIED
errors.
1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1621 def set_table_iam_policy(resource, set_iam_policy_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:post, '{+resource}:setIamPolicy', ) command.request_representation = Google::Apis::BigqueryV2::SetIamPolicyRequest::Representation command.request_object = set_iam_policy_request_object command.response_representation = Google::Apis::BigqueryV2::Policy::Representation command.response_class = Google::Apis::BigqueryV2::Policy command.params['resource'] = resource unless resource.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#test_row_access_policy_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::TestIamPermissionsResponse
Returns permissions that a caller has on the specified resource. If the
resource does not exist, this will return an empty set of permissions, not a
NOT_FOUND
error. Note: This operation is designed to be used for building
permission-aware UIs and command-line tools, not for authorization checking.
This operation may "fail open" without warning.
1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1230 def (resource, = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:post, '{+resource}:testIamPermissions', ) command.request_representation = Google::Apis::BigqueryV2::TestIamPermissionsRequest::Representation command.request_object = command.response_representation = Google::Apis::BigqueryV2::TestIamPermissionsResponse::Representation command.response_class = Google::Apis::BigqueryV2::TestIamPermissionsResponse command.params['resource'] = resource unless resource.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#test_table_iam_permissions(resource, test_iam_permissions_request_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::TestIamPermissionsResponse
Returns permissions that a caller has on the specified resource. If the
resource does not exist, this will return an empty set of permissions, not a
NOT_FOUND
error. Note: This operation is designed to be used for building
permission-aware UIs and command-line tools, not for authorization checking.
This operation may "fail open" without warning.
1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1663 def (resource, = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:post, '{+resource}:testIamPermissions', ) command.request_representation = Google::Apis::BigqueryV2::TestIamPermissionsRequest::Representation command.request_object = command.response_representation = Google::Apis::BigqueryV2::TestIamPermissionsResponse::Representation command.response_class = Google::Apis::BigqueryV2::TestIamPermissionsResponse command.params['resource'] = resource unless resource.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#update_dataset(project_id, dataset_id, dataset_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Dataset
Updates information in an existing dataset. The update method replaces the entire dataset resource, whereas the patch method only replaces fields that are provided in the submitted dataset resource.
287 288 289 290 291 292 293 294 295 296 297 298 299 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 287 def update_dataset(project_id, dataset_id, dataset_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:put, 'projects/{projectId}/datasets/{datasetId}', ) command.request_representation = Google::Apis::BigqueryV2::Dataset::Representation command.request_object = dataset_object command.response_representation = Google::Apis::BigqueryV2::Dataset::Representation command.response_class = Google::Apis::BigqueryV2::Dataset command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#update_routine(project_id, dataset_id, routine_id, routine_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Routine
Updates information in an existing routine. The update method replaces the entire Routine resource.
1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1061 def update_routine(project_id, dataset_id, routine_id, routine_object = nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:put, 'projects/{+projectId}/datasets/{+datasetId}/routines/{+routineId}', ) command.request_representation = Google::Apis::BigqueryV2::Routine::Representation command.request_object = routine_object command.response_representation = Google::Apis::BigqueryV2::Routine::Representation command.response_class = Google::Apis::BigqueryV2::Routine command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.params['routineId'] = routine_id unless routine_id.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |
#update_table(project_id, dataset_id, table_id, table_object = nil, autodetect_schema: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil) {|result, err| ... } ⇒ Google::Apis::BigqueryV2::Table
Updates information in an existing table. The update method replaces the entire table resource, whereas the patch method only replaces fields that are provided in the submitted table resource.
1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 |
# File 'lib/google/apis/bigquery_v2/service.rb', line 1707 def update_table(project_id, dataset_id, table_id, table_object = nil, autodetect_schema: nil, fields: nil, quota_user: nil, user_ip: nil, options: nil, &block) command = make_simple_command(:put, 'projects/{projectId}/datasets/{datasetId}/tables/{tableId}', ) command.request_representation = Google::Apis::BigqueryV2::Table::Representation command.request_object = table_object command.response_representation = Google::Apis::BigqueryV2::Table::Representation command.response_class = Google::Apis::BigqueryV2::Table command.params['projectId'] = project_id unless project_id.nil? command.params['datasetId'] = dataset_id unless dataset_id.nil? command.params['tableId'] = table_id unless table_id.nil? command.query['autodetect_schema'] = autodetect_schema unless autodetect_schema.nil? command.query['fields'] = fields unless fields.nil? command.query['quotaUser'] = quota_user unless quota_user.nil? command.query['userIp'] = user_ip unless user_ip.nil? execute_or_queue_command(command, &block) end |