Chapter 6. Using Expressions and Variables

If you have used SSIS or DTS packages for any involved ETL process, you have inevitably encountered the need to have dynamic capabilities. A dynamic package can reconfigure itself at runtime to do things like run certain steps conditionally, to create a series of auto-generated filenames for export, or to retrieve and set send-to addresses on an alert email from a data table. The paradigm shifted radically on how to do this as SQL Server evolved from DTS to the current SSIS packages and frankly, expressions was one of the features that was under-represented in the Books Online. As a result, the concept of expressions was a topic of many inquires as developers and architects began rolling out SSIS projects in their development shops.

This chapter is our attempt to remedy the confusion and get you up to speed on expressions. Here we will consolidate the common questions, answers, and best practices about expressions that we've been hearing about and explaining since the first release of SSIS. The good news is that expressions are easy to use and impressively powerful. The even better news is that Microsoft has now supplemented the Books Online with a hefty section on expressions. As you read this chapter you will gain an understanding not only about how expressions work, but you'll also gain some insight to how you can use expressions now on your current SSIS project.

The Paradigm

The model in DTS for realizing values and stuffing them into ...

Get Professional SQL Server® 2008 Integration Services now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.