Click here to monitor SSC
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


SSIS performance Insert Update and Delete


SSIS performance Insert Update and Delete

Author
Message
Ells
Ells
Right there with Babe
Right there with Babe (790 reputation)Right there with Babe (790 reputation)Right there with Babe (790 reputation)Right there with Babe (790 reputation)Right there with Babe (790 reputation)Right there with Babe (790 reputation)Right there with Babe (790 reputation)Right there with Babe (790 reputation)

Group: General Forum Members
Points: 790 Visits: 931
This is a bit of a hybrid question between T-SQl and SSIS

I am looking at using CDC to load a data warehouse. Now with no warning of number of changes I am planning to make it as performant as possible.

I have one table with Insert / Update / Delete commands. I then plan to action these changes through SSIS. At first glance this seemed to be split the feed into three using conditional split and then to use OLE DB destination for the insert, 2 OLE DB command tasks (one for delete and one for insert). This is how MS have done it in one of their example packages.

Now I woukld like to challenge this. Surely the uuse of OLE DB command means the changes (updates and deletes) will be executed row by row?

Surely three Execute SQL TAsks would be better? Could they be faster than OLEDB Destination (Inserts), OLEDB Command (Update), OLEDB Command (Delete).

As this package will be used as a template I am sure I could make the Execute SQL task use a dynamic SQL statement.

Your thoughts much appreciated.

M
Cool
cafescott
cafescott
SSC-Enthusiastic
SSC-Enthusiastic (166 reputation)SSC-Enthusiastic (166 reputation)SSC-Enthusiastic (166 reputation)SSC-Enthusiastic (166 reputation)SSC-Enthusiastic (166 reputation)SSC-Enthusiastic (166 reputation)SSC-Enthusiastic (166 reputation)SSC-Enthusiastic (166 reputation)

Group: General Forum Members
Points: 166 Visits: 733
I would keep all the insert/update/delete logic possible in a single stored procedure, and just have SSIS call the procedure. This minimizes the number of connections the package makes to the database.
Ells
Ells
Right there with Babe
Right there with Babe (790 reputation)Right there with Babe (790 reputation)Right there with Babe (790 reputation)Right there with Babe (790 reputation)Right there with Babe (790 reputation)Right there with Babe (790 reputation)Right there with Babe (790 reputation)Right there with Babe (790 reputation)

Group: General Forum Members
Points: 790 Visits: 931
Had not thought of that. However that will require me writing 30+ stored Procedures as well as the packages. Experimenting with dynamic code inside the Execute Sql Task that may allow me to get away with a lot of code reuse.

Hoping to do it in SSIS rather than stored procedures.

Thanks
M
Phil Parkin
Phil Parkin
SSCrazy Eights
SSCrazy Eights (8.4K reputation)SSCrazy Eights (8.4K reputation)SSCrazy Eights (8.4K reputation)SSCrazy Eights (8.4K reputation)SSCrazy Eights (8.4K reputation)SSCrazy Eights (8.4K reputation)SSCrazy Eights (8.4K reputation)SSCrazy Eights (8.4K reputation)

Group: General Forum Members
Points: 8389 Visits: 19503
SSIS is extremely fast at INSERTs - I'd suggest leaving those to SSIS.

Updates and deletes I would direct to a staging area and then MERGE via a T-SQL stored proc.

I appreciate that you want to keep this in SSIS as much as possible, but I don't think you'll achieve your 'performant as possible' requirement that way.


Help us to help you. For better, quicker and more-focused answers to your questions, consider following the advice in this link.

If the answer to your question can be found with a brief Google search, please perform the search yourself, rather than expecting one of the SSC members to do it for you.

Please surround any code or links you post with the appropriate IFCode formatting tags. It helps readability a lot.
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search