-
Create a Google account or be able to log in to an existing one
-
Log into the Google Cloud Console and create project or locate an existing project and record the project ID for use in a later step
-
Run this command in your terminal to log in with the Google Cloud CLI:
gcloud auth application-default login
-
Install the BigQuery ADBC driver:
dbc install bigquery
-
Customize the Go program
main.goas needed- Change the connection arguments in the
NewDatabase()call- Change the value of the
adbc.bigquery.sql.project_idargument to match the project ID you recorded in the earlier step - Change the value of
adbc.bigquery.sql.dataset_id, or keep it to use the public Shakespeare dataset
- Change the value of the
- If you changed the dataset, also change the SQL SELECT statement in
stmt.SetSqlQuery()
- Change the connection arguments in the
-
Run the Go program:
go mod tidy go run main.go