← BigQuery552 / 640
hardbq

Run a BigQuery query and write the results to a destination table

command

bq query --use_legacy_sql=false --destination_table=DATASET.RESULTS_TABLE 'SELECT * FROM DATASET.TABLE'

also accepted

bq query --destination_tablebq query --use_legacy_sql=false --destination_table

Command breakdown

Part of the BigQuery CLI (bq) — BigQuery category.

bqquery--use_legacy_sql=false--destination_table=DATASET.RESULTS_TABLE'SELECT*FROMDATASET.TABLE'
FlagPurpose
--use_legacy_sqlSet to: false
--destination_tableSet to: DATASET.RESULTS_TABLE

Test your recall — not just your reading.

Practice with interactive quiz →