Howard Lau
Howard Lau

Reputation: 173

Insert/update Firestore document export in Google BigQuery

I have a Firestore docuement like as like below and it is exported to Storage enter image description here

Then, I have created a table for the document in Google BigQuery.

enter image description here

I have tried to write an update/insert query.

UPDATE `dataset.feed` set d_1.0 = "Imagelink"

also, tried to use UNNEST to breakdown the array by following the Firestore documentation. Still, I can't figure out how to write an update/insert for a document.

Upvotes: 1

Views: 109

Answers (1)

Sergey Geron
Sergey Geron

Reputation: 10222

Array can only be updated as a whole:

UPDATE `dataset.feed` SET d_1 = ["t0", "t1"] WHERE ...

Upvotes: 0

Related Questions