October 22, 2012 at 5:15 pm
I am trying to create a for each loop and inside the loop add a dataflow where I pass in a variable with a dynamic query where the only part that changes on iteration of the loop is the table name. I'm doing this because I have 50 databases with 700 tables in each that need to be migrated to another database. I'm begining to think that it may not be possible because the metadata will change on each iteration.
I have it set up to use a Transfer SQL Server Objects task and it works but I dont like the idea of not having any error handling with the task. Is there a way to catch the error and use an exe sql task to insert the name of the table to a log table that caused the error with an Transfer SQL Server Objects task ?
October 23, 2012 at 12:35 am
No. SSIS can't handle the changing metadata.
Maybe using the Import/Export wizard can be an option?
Need an answer? No, you need a question
My blog at https://sqlkover.com.
MCSE Business Intelligence - Microsoft Data Platform MVP
October 25, 2012 at 12:10 pm
As Koen have stated this is not possible with the standard SSIS, which only supports static metadata. This means you have to create separate data flow for each table you want to process.
If you can use third-party components, check the commercial COZYROC Data Flow Task Plus. It is an extension of the standard Data Flow Task and it supports dynamic columns at runtime. You can process all your tables with only one For Each Loop (FEL) container and one COZYROC Data Flow Task Plus. No programming skills are required.
October 25, 2012 at 12:37 pm
Nice! I will see if we can use 3rd party
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply