How to: Create a Property Expression

You can create property expressions for packages, tasks, Foreach Loop containers, For Loop containers, Sequence containers, event handlers, connection managers, and log providers. The property expressions are created after the item is added to the package. For information about adding items to packages, see the following topics:

The Property Expressions Editor and Expression Builder are accessible from the custom editors for tasks and loops and from the Properties window. You can use either tool to write expressions, but the Expression Builder provides a graphical set of tools that makes it simple to build complex expressions.

To learn more about the syntax, operators, and functions that SQL Server 2005 Integration Services (SSIS) provides, see Integration Services Expression Concepts, Operators (SSIS), and Functions (SSIS).

The topics for each operator and function includes examples of using the operator or function in an expression. For examples of more complex expressions, see Using Property Expressions in Packages.

  1. In Business Intelligence Development Studio, open the project that contains the Integration Services package you want.

  2. In Solution Explorer, double-click the package to open it, and then do one of the following:

    • If the item is a task or a loop, double-click the item, and then click Expressions in the editor.
    • Right-click the item and then click Properties.
  3. Click in the Expressions box and then click the ellipsis (…).

  4. In the Property Expressions Editor, select a property in the Property list, and then do one of the following:

    • Type an expression in the Expression column and click OK.
    • Click the ellipsis (…) in the expression row of the property.
  5. In the Expression Builder, expand Variables to access system and user-defined variables.

  6. In the right pane, expand Mathematical Functions, String Functions, Date/Time Functions, NULL Functions, Type Casts, and Operators to access the functions, the casts, and the operators that the SSIS expression language provides.

  7. To build an expression, drag variables, columns, functions, operators, and casts to the Expression box or type the expression in the box.

  8. Optionally, click Evaluate Expression to view the evaluation result of the expression. If the expression is not valid, an alert appears that describes the syntax errors in the expression.

    Evaluating an expression does not assign the evaluation result to the property.

  9. Click OK.

Community Additions