Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Loading CSV files from Google Drive to BigQuery

I would like to have my CSV data from Google Drive completely downloaded to Bigquery, like a native table in it. However, the Table type option is not available when I want to upload my data, I have no choice but to use the "external table" option.

This is really unconvenient, as the amount of data I will get in the future will become too important for a Drive Storage.

My question is: is it possible to load a CSV file from Drive to BigQuery as a native table, or do I have to use Google Storage between the two, making the process even more complicated than it already is?

like image 953
il_Cozzimo Avatar asked Mar 09 '26 15:03

il_Cozzimo


1 Answers

  1. Create an external table of the files on Drive.
  2. Run a query of the form CREATE TABLE dataset.NewTable AS SELECT * FROM dataset.ExternalTable. Now you have the file contents in a BigQuery-managed table without having to copy to Cloud Storage.
like image 75
Elliott Brossard Avatar answered Mar 11 '26 05:03

Elliott Brossard



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!