0
votes

We're doing streaming inserts on a BigQuery table.

We want to update the schema of a table without changing its name.

For example, we want to drop a column because it has sensitive data but we want to keep all the other data and the table name the same.

Our process is as follows:

  • copy original table to temp table
  • delete original table
  • create new table with original table name and new schema
  • populate new table with old table's data
  • cry because the last (up to) 90 minutes of data is stuck in streaming buffer and was not transferred.

How to avoid the last step?

1
Is your streaming data already fitting the new schema? - rmesteves

1 Answers

1
votes

I believe the new streaming API does not use streaming buffer anymore. Instead, it writes data directly to the destination table.

To enable API you have to enroll with BigQuery Streaming V2 Beta Enrollment Form:

You can find out more in the following link I hope it addresses your case.