Using Configuration Files


If you use indirect configurations, you must specify one environment variable for each configuration. Using direct and indirect configurations is discussed later in this chapter.

Typically, the most flexible way to use configurations is to use an environment variable or registry entry that contains a connection string to a SQL Server database containing SQL Server configurations. You should list this configuration first in the Package Configuration Organizer, and then the remaining configurations should use SQL Server or parent package variable configurations.

Determining Configuration Order

Configurations are applied in the order in which they are listed in the Package Configuration Organizer with one exception: Parent package variable configurations are always applied last. If multiple configurations contain the same package property, the property is set to the value in the last applied configuration. Because parent package variable configurations are applied last, you should ensure that other configurations are not dependent on them.

Evaluating Configuration Failure

If a configuration fails (for example, you give the wrong location for an XML configuration file), the package will continue to execute using the values set for the properties in the package. Configuration failure generates a warning but not an error. Package execution is momentarily slowed by a configuration error.

Using Multiple Configurations

XML configuration files and SQL Server configurations can contain multiple package properties. For example, a single configuration can contain the connection strings to all of the source and target files and databases. All the packages can then read this configuration. However, because not all packages use all of the sources and targets, warnings are generated when the packages read the configuration. It is better to create multiple XML or SQL Server configurations, one configuration per set of related properties. For example, you could create one configuration that contains the connection string and text qualifier for a source text file and another configuration containing the connection string for a target database. This way, each package reads only the configurations it needs.




Microsoft SQL Server 2005 Integration Services Step by Step
MicrosoftВ® SQL Server(TM) 2005 Integration Services Step by Step
ISBN: 0735624054
EAN: 2147483647
Year: 2007
Pages: 152

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net