🐛 firestore-bigquery-export - backup and remove old changelog rows #2222
Open
Description
opened on Nov 26, 2024
[REQUIRED] Step 2: Extension name
This feature request is for extension: _ (firestore-bigquery-export
)
What feature would you like to see?
Add the ability to automatically backup the change log rows into another table and delete them from the _raw_changelog table.
The large amount of data in this table is causing substantial cost increases to queries.
How would you use it?
This is my stackoverflow.
My current process is to make a copy of the _raw_changelog table and then use the SQL in the link above to delete the old changelog rows.
DELETE FROM your_dataset.your_table
WHERE STRUCT(document_name, timestamp) NOT IN (
SELECT AS STRUCT document_name, MAX(timestamp) AS timestamp
FROM your_dataset.your_table
GROUP BY document_name
)
Activity