I’m writing an ETL to load multiple tables.
To minimize downtime (blocking) of reporting workload, and inconsistent data, I’m planning to use a pattern like the following to achieve the all or nothing goal (in a transaction):
https://medium.com/codex/stabilize-your-etl-based-data-offerings-via-schema-table-switching-example-with-sql-server-133ff5e26b38
I’m seeking help to understand what purpose does step 2 serve? And what would be the problem if instead I swap the live and staging?
7