Help Desk

Submit a ticket My Tickets
Welcome
Login

Google BigQuery Command Reference

The Google BigQuery allows you to load and query for data in a tabular format. It also includes commands for finding the associated metadata with your projects, tables, datasets, and more.

Connections

Google BigQuery

Google BigQuery service account connection

Inputs

Input Type Detail Notes
Project ID TextField Your BigQuery Project ID The Project ID can be found by clicking the Project selector in the top bar of the BigQuery UI
Credentials File FileField Your service account credentials JSON file This file gets generated when creating your service account. See the following link for more details: https://cloud.google.com/iam/docs/creating-managing-service-accounts

Commands

Get Dataset

Get details about a BigQuery dataset

Inputs

Input Type Detail Notes
Dataset ID TextField The ID of your dataset for which you are querying

Outputs

Output Output Type Notes
Dataset JSON File

Exit Codes

Code Type Detail
0 Success Completed successfully
1 Error General failure

Get Model

Get details about a BigQuery model

Inputs

Input Type Detail Notes
Model ID TextField The ID of your model
Dataset ID TextField The ID of your dataset which contains the model for which you are querying

Outputs

Output Output Type Notes
Model JSON File

Exit Codes

Code Type Detail
0 Success Completed successfully
1 Error General failure

Get Routine

Get details about a BigQuery routine

Inputs

Input Type Detail Notes
Routine ID TextField The ID of your routine
Dataset ID TextField The ID of your dataset which contains the routine for which you are querying

Outputs

Output Output Type Notes
Routine JSON File

Exit Codes

Code Type Detail
0 Success Completed successfully
1 Error General failure

Get Table

Get details about a BigQuery table

Inputs

Input Type Detail Notes
Table ID TextField The ID of your table
Dataset ID TextField The ID of your dataset which contains the table for which you are querying

Outputs

Output Output Type Notes
Table JSON File

Exit Codes

Code Type Detail
0 Success Completed successfully
1 Error General failure

List Datasets

List all Datasets for a given Project

Inputs

None

Outputs

Output Output Type Notes
Datasets JSON File

Exit Codes

Code Type Detail
0 Success Completed successfully
1 Error General failure

List Models

List all Models for a given Dataset

Inputs

Input Type Detail Notes
Dataset ID TextField The ID of your Dataset

Outputs

Output Output Type Notes
Models JSON File

Exit Codes

Code Type Detail
0 Success Completed successfully
1 Error General failure

List Projects

List all Projects for a given user

Inputs

None

Outputs

Output Output Type Notes
Tables JSON File

Exit Codes

Code Type Detail
0 Success Completed successfully
1 Error General failure

List Routines

List all Routines for a given Dataset

Inputs

Input Type Detail Notes
Dataset ID TextField The ID of your Dataset

Outputs

Output Output Type Notes
Routines JSON File

Exit Codes

Code Type Detail
0 Success Completed successfully
1 Error General failure

List Table Data

Returns all data in a given table in a tabular format

Inputs

Input Type Detail Notes
Dataset ID TextField The ID of your Dataset
Table ID TextField The ID of the table from which you want to return data
Preview Data BooleanField Optionally preview the data.

Outputs

Output Output Type Notes
Table Data CSV File
Row Count Integer

Exit Codes

Code Type Detail
0 Success Completed successfully
1 Error General failure

List Tables

List all Tables for a given Dataset

Inputs

Input Type Detail Notes
Dataset ID TextField The ID of your Dataset

Outputs

Output Output Type Notes
Tables JSON File

Exit Codes

Code Type Detail
0 Success Completed successfully
1 Error General failure

Load Data

Loads tabular data into a given table

Inputs

Input Type Detail Notes
Dataset ID TextField The ID of your Dataset
Table ID TextField The ID of the table from which you want to return data
File FileField Tabular data file to be loaded to BigQuery.
Data File Delimiter DropdownField The delimiter of the CSV file that is being loaded
Write Mode DropdownField The method used to load your data. You can either overwrite, append, or write in "safe" mode where the write will only succeed on an empty table
Schema TextField Optional: Schema for the data you are loading. If left blank, BigQuery will automatically detect the schema. If you choose to enter schema, it must be a JSON array with name, type, and mode fields. See documentation for more information. Your table's schema is available in the BigQuery UI. Simply select your table in the left menu and you'll see the name, type, and mode of each field.

Outputs

Output Output Type Notes
Rows Processed Integer
Errors File

Exit Codes

Code Type Detail
0 Success Completed successfully
1 Error General failure

Query Data

Extracts data from BigQuery in a tabular format, given a query

Inputs

Input Type Detail Notes
Query TextField BigQuery query statement. While the query language is similar to SQL, there are some important differences. See the documentation for more information. You can read more about the BigQuery query syntax at: https://cloud.google.com/bigquery/docs/reference/standard-sql/query-syntax
Query Location TextField Location of the data you are querying. Note that it will be set to "US" if no value is provided.
Preview Data BooleanField Whether or not to show a preview of the data returned from the query

Outputs

Output Output Type Notes
Query Output File File
Record Count Integer

Exit Codes

Code Type Detail
0 Success Completed successfully
1 Error General failure
B
Brian is the author of this solution article.

Did you find it helpful? Yes No

Send feedback
Sorry we couldn't be helpful. Help us improve this article with your feedback.