Greetings All
So I am in a predicament. Hopefully, experts here might be able to solve this for me.
I need to move data for some specific tables from Server1 to Server2. This needs to be done using SSIS but no buseness logic or rules can live within SSIS and the SSIS package should be metadata changes independent. That is to say that if the source query
changes, I should not have to modify anything in SSIS.
While thinking about this, you can safely make the following assumptions:
1. Both servers are SQL Server 2008 or higher.
2. Source server is read only and we cannot make any changes
3. We cannot use linked servers (not a good idea anyway)
4. We cannot use database replication/mirroring/log shipping etc.
5. Some of the tables have records in tens of millions
Some approaches I have been thinking about:
1. Have the sql code in a .sql file and then use the execute sql task. This works if I load the query from the file and run it on the destination server but that would mean using linked server to read data from the source server. But, I cannot use linked
server and even if I could, I don't think it is a good idea anyway.
2. Load the select query from a .sql file, run it on the source server, download the the data to an intermediatory solution (I was thinking of RAW files) and then a second step that reads from the intermediatory. So far this is a bust as the set up requires
me to select the columns to be written to the RAW file and I cannot have metadata dependency inside SSIS. The step should pick up all available columns automatically.
The overall idea is that if down the road we need to modify the sql queries, all we have to do is to open the sql file, make changes to the sql query and you are done. We shouldn't have to touch the SSIS at all. The SSIS is only assisting in iterating through
the set of sql files, running them and logging the results.
Thank you in advance for your help.
P.
- Edited by pkssandhu 16 hours 51 minutes ago