ScriptGuy
ScriptGuy

Reputation: 101

SSIS Package configuration environment variable was not found while calling it using xp_cmdshell?

I have a SSIS package which loads data from flat file into SQL server Table. For configuration, I'm using package configuration method of using environment variables where we can store the XML file path in variable.

If the package runs using DTEXEC utility or SQL Job, package detects the env variable and it ran the package fine without any issues.

If i tried to do execute the package with XP_CMDSHELL procedure, its returning the message saying "package was not able to find "XXXX" environmental variable".

Even I restarted the SQL Server Agent once i created the environment variable.

Upvotes: 3

Views: 1512

Answers (1)

ScriptGuy
ScriptGuy

Reputation: 101

Finally I figured it out, to get this done we have to restart the SQL Service.

Upvotes: 1

Related Questions