Share via

Copy massive data from between 2 SQL Instances

Pedro Soares 406 Reputation points
2022-05-01T18:59:14.09+00:00

Hi guys,

I'm trying to figure out the best approach due to an architectural constraint. I have a public organization that demands that the final DWH layer is segregated from the ODS / Staging Area, on 2 diferent instances.

While I believe this is an horrible approach and that the Staging and final Data Warehouse cannot be black boxes and they must communicate between them for proper and efficient data flow, I'm stuck with this option for now. Since they don't even allow linked servers between both instances the only communication between them can only be made through SSIS.

Since I use the SQL Merge command for Dimension and Fact Loading, since the tables have a noticeable size, even in incremental loads, since records can be updated, I don't have any optimal way to run ETL.

My option was to create a DWH schema under the ODS database, that is copied to the final EDW SQL instance. This however needs to synced everyday by truncating all the tables and copy millions of rows every single day.

I believe this is a stupid, poorly architecture design, but anyway, maybe some brainstorm will help ease the process.

Azure Synapse Analytics
Azure Synapse Analytics

An Azure analytics service that brings together data integration, enterprise data warehousing, and big data analytics. Previously known as Azure SQL Data Warehouse.


Answer accepted by question author

Lulzim Bilali 76 Reputation points
2022-05-02T14:18:51.89+00:00

As I understand from your question today you are loading the DWH on the stage instance and than coping it to the DWH instance.

couple of options I was providing where:

  1. based on a load_date identify what is new/updated/deleted and move only the rows that rows instead of everything.
  2. you can identify what changed by using CDC instead of using a load_date
  3. you can use log shipping https://learn.microsoft.com/en-us/sql/database-engine/log-shipping/about-log-shipping-sql-server?view=sql-server-ver15
  4. or another alternative: you can create DWH as a database on stage instead of a schema and do a backup / restore

Was this answer helpful?


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.