Friday, December 31, 2010

SSIS: SSIS Configuraion: Why SSIS Package do not find my environment variable?

This is my first post on SSIS.

SSIS is something I seriously started loving this year. I started with BIDS 2008. In this very first post I am going to share an experience which I come across.

SSIS provides 5 ways to store the package configuration.

  1. XML Configuration file
  2. Environment Variables
  3. SQL Server Tables
  4. Registry entry
  5. Parent package variable


I used the combination of 1st and 2nd. That is all my configuration information was stored in XML file. In the environment variables I stored the physical path of the XML file. My SSIS package was reading the environment variable and loading the configuration information written in the XML file.

During the Development environment I created the environment variable as User Variables and developed my SSIS package. Everything was smooth and package was reading the configuration file correctly.

When I moved the package to production environment and created the environment variable at user level; my package which was part of a batch file stops reading environment variable and throwing errors like cannot read environment variable. After a lot of research I came across the solution. I moved the environment variables form User variables to System Variables and re-booted the machine. My issue got resolved and package starts to run smoothly.

..A bit unusual was lesson for me was to always set your environment variables as System Variables in production environment.

Popular Posts

Real Time Web Analytics