December 2017
Beginner to intermediate
264 pages
5h 38m
English
Run the following command to query and show the first name from the CSV file. This command specifies the external data source and provides an alias name for the temporarily linked table as employees and run the specified query:
bq query --external_table_definition=employees::tabledefinition.txt 'SELECT EMPLOYEE_FIRST_NAME FROM employees;'
To create a permanent linked table for the file in Google Cloud Storage, run the following command. This command will create a new permanent link in BigQuery between the file and an alias in BigQuery under the specified dataset:
bq mk --external_table_definition=tabledefinition.txt HumanResourceDS.Employees_Linked
The linked table can be queried like a normal table ...