Where did the option "Delete rows in destination table" go?

  • Hi,

    I created an SSIS Package to import a table from an Oracle source.  Since this table did not exist in the destination database, the Column Mappings window automatically selected the "Create destination table" option.  I saved the Package and executed it and it completed successfully.

    Now I need to import the data again, so I need to edit the Package to delete the rows in the destination table.  I opened the Package in the BI Dev Studio.

    Where can I change the "Create destination table" option to "Delete rows in destination table"?  I've looked all over the place.

    Thanks.

    Tim

  • Add an "Data Flow Task" Event Handler "OnPreExecute" 

    Add "Execute SQL Task" to EventHandler  enter delete statement for that table in SQL Task

    hope it will solve your problem

  • I found this potentially very useful and so implemented it happily... however, a warning; when designing/debugging I couldn't get it to fire the event if I just executed the individual task associated with it i.e. right-clicking on the data flow task which wants an empty-table and choosing "Execute Task" does not fire the trigger.  For that you need to execute the whole package. I think it has something to do with the way events "bubble up" through the package.

    Oh, and be careful about putting it on the pre-ex event of a Sequence Container with your table population task inside it; there's weird asynchronous stuff going on at first sight and it truncated the table after I'd loaded it.  Not too sure on that one, but beware, you could be tearing your hair out for a couple of hours (I just have).

    Matt

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply