Medium1 markMultiple Choice
GCP ACE · Question 27 · Domain 3.4: Deploying and implementing data solutions
You have a 50 GB CSV file stored in a Cloud Storage bucket (gs://my-data-bucket/sales.csv). You need to load this data into a BigQuery table named sales_data in the finance dataset.
Which command should you use?
You have a 50 GB CSV file stored in a Cloud Storage bucket (gs://my-data-bucket/sales.csv). You need to load this data into a BigQuery table named sales_data in the finance dataset.
Which command should you use?
Answer options:
A.
gsutil cp gs://my-data-bucket/sales.csv bq://finance/sales_data
B.
gcloud bigquery load gs://my-data-bucket/sales.csv finance.sales_data
C.
bq load --source_format=CSV finance.sales_data gs://my-data-bucket/sales.csv
D.
bq import gs://my-data-bucket/sales.csv finance.sales_data
How to approach this question
Identify the correct CLI tool for BigQuery and the specific command for loading data.
Full Answer
C.bq load --source_format=CSV finance.sales_data gs://my-data-bucket/sales.csv✓ Correct
bq load --source_format=CSV finance.sales_data gs://my-data-bucket/sales.csv
The `bq` command-line tool is used to interact with BigQuery. The `bq load` command is specifically used to load data into BigQuery tables from various sources, including Cloud Storage. You specify the format, the destination table (`dataset.table`), and the source URI.
Common mistakes
Trying to use `gsutil cp` or `gcloud bigquery`. Remember that BigQuery uses the `bq` tool.
Practice the full GCP Associate Cloud Engineer Practice Exam 7
50 questions · hints · full answers · grading
More questions from this exam
Q01You are starting a new initiative and need to create a new Google Cloud project using the Cloud S...EasyQ02Your company is migrating to Google Cloud and wants to manage user identities centrally. They cur...MediumQ03You have just created a new Google Cloud project and want to deploy a containerized application u...MediumQ04Your finance team wants to perform complex SQL queries on your Google Cloud billing data to analy...MediumQ05You are managing a development project in Google Cloud. You want to ensure that you are notified ...Easy
Expert