Archive for July, 2014

How to differentiate in SSIS between design and execution mode

July 29th, 2014

Sometimes it is necessary to differentiate between design and execution mode. For example when you dynamically generate tables in your SSIS package. By making your package aware of the differences between design and execution mode, you can use existing tables during design mode but switch to the dynamically generated tables during execution mode. All you need to do is set the source for your table to a variable, and add the following expression to that variable.

@[System::CancelEvent] == 0 ? "Design mode" : "Execution mode"

The key is the System variable CancelEvent. This will be 0 when you are running in design mode, but will contain an integer during execution.

Posted in SSIS | Comments (0)

SEO Powered by Platinum SEO from Techblissonline