简体   繁体   中英

How can I move data from BigQuery to same database in BigQuery but different schema?

I am trying to move the data from Financial Schema tables to Looker_Scratch Schema tables.

There are a few different ways to do this:

  1. Using the UI follow the instructions in the documentation for copying a single source table .
  2. Utilize the table snapshot function as described here: https://cloud.google.com/bigquery/docs/table-snapshots-create
  3. Create a view to in the scratch dataset that points to the original.

The benefit to the snapshot is that it would be that it stores less data on disc than a full copy, however in both scenarios one and two above the data would become stale unless you put some kind of scheduled query or process behind it to refresh. The view method would allow you to have the data be up to date as of the execution, this could present permissions issues so you may also want to look into authorized views.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM