SSIS Config problem
Not having read all of this thread, I offer this AGAIN:
You CAN specify Configurations in Child Packages. I do it all the time. I execute them from SQL Agent and since the child packages (and the parents) are DESIGNED with the Configurations, I do NOT need to specify any at run-time.
Try this little experiment:
Create a simple Parent package that calls a Child Package.
Design the Child to use an XML configuration for a setting that you can verify.
Before you run the Parent via command line DTEXEC, edit the entry in the XML file
Run the package and you will see that the child picks up on the new XML value even though you do not specify any Configs in the DTEXEC command.
It works, trust me.Todd C - MSCTS SQL Server 2005 - Please mark posts as answered where appropriate.
July 2nd, 2011 9:33am
Need some config explenation
Here is my situation.
The config in my Main package is set via a .dtsConfig file (the config file sets the connectionstring to the config database). From there on the
connectionstring to config database is passed on via Parent-Child variables.
I cannot use env. variables.
Everything worked fine until I needed to set my connection via Windows Authentication, suddenly I've got tons of errors while executing my package
via dtexec => anonymous user,... my windowsId got lost (no problem for me). In dev the .dtsConfig file & my config db is still working with sql users.
What I don't understand is why my process fails due to validation errors. Normally during the process after setting the config from my database,
it should work fine no?
Bram
Free Windows Admin Tool Kit Click here and download it now
July 2nd, 2011 11:07am
So your Child packages all have Variables that contain Connection String info, and then all the Connecton Managers have an Expression that is based on the relative Variable?
Seems in-efficient.
Why not just use the same .dtsConfig XML connection to the SSIS Configuration database for each child package? It's only one more hit to the database per executeion, not like you're going to be hitting that Db thousands of times, right?Todd C - MSCTS SQL Server 2005 - Please mark posts as answered where appropriate.
July 2nd, 2011 12:55pm
If you're getting validation errors, and not execution errors, I believe that's probably because you need to put in a valid default value for the expression(s) that is eventually going to be overwritten by your configuration.-Tab Alleman
Free Windows Admin Tool Kit Click here and download it now
July 2nd, 2011 1:16pm
Todd,
All config (conn strings, variables, ...) are stored in a SQL server config table. As I cannot use sys. env. variables, I pass the connectionstring of the SQL config table via an xml .dtsConfig file. As far as I know you can only apply the config
file to the package you execute (main package) not the child packages, that's why I use parent-child variables (only for the connectionstring of my config db.). I cannot use fix path either as the packages aren't even located on the SSIS server. (very dynamic
and secure environment).
I know in sql server 2008 the validation process has changed. So it first applies the connectionstring in the variable that was set at design time and after it overwrites this variable with the value of it's parent, which sets the connectionstring to the
config database, where all other configuration is stored.
I know the configuration works as it runs on different environments, but when my parent-child variable is
invallid at design time, I cannot start my package at runtime
Here are the steps of this configuration:
1. dtexec /f "...main.dtsx" /Conf "...Conf.dtsConfig" (contains connectionstring of sql config database)
2. in the main the variable config is set with the value stored in the sql config database (as i cannot pass my config file to my child packages)
3. via parent-child config, my config variable is set via the variable of its parent. This config variable sets the connectionstring (via expressions) of my config database.
July 3rd, 2011 2:21am
As far as I know you can only apply the config file to the package you execute (main package) not the child packages, that's why I use parent-child variables (only for the connectionstring of my config db.). I cannot use fix path either as the packages
aren't even located on the SSIS server. (very dynamic and secure environment).
That is not correct. You can apply the xml-file to each subpackage.
But I agree with Tab Alleman. Use Default values and set DelayValidation to true
Free Windows Admin Tool Kit Click here and download it now
July 3rd, 2011 2:32am
Hi Tab,
You are correct, but at design time I switched to windows authentication, I execute dtexec via psExec and there I loose my Windows id so it runs the package under
anonymous user.
However in dev at runtime via my configuration, I still use sql users but I got errors that the anonymous user doesn't have the rights :-).
In order to fix this I had to set each config variable of all my package with the connectionstring using sql users, which was a lot of work.
So in fact everything works, but how is it possible that my package can fail because the connectionstring to my config database is wrong (it will be replaced by the
parent-child config with the correct string). So it fails my package before it applies the configuration first!?
There must be something that I miss as I cannot see the logic.
I hope this forum clears it all out :)
Thanks in
advance,
Bram
July 3rd, 2011 2:34am
I'm sorry applying the xml-file to the child packages is new for me, could you explain me how this works? Does this work's automatically? So if all my connectionsmanagers
have the same name, they will all be overwritten by this config file?
And setting the DelayValidation to true, is this only required to config connection manager ,or to all my connection managers, or in the properties of my control
flow of the package, or to the execute package task? It looks like every component has this property :-)
Thanks in advance!
Free Windows Admin Tool Kit Click here and download it now
July 3rd, 2011 2:44am
If you work with SSIS2005, all configuered values (Connection Managers, Variables etc.) have to be in the package, then the configuration will work fine. Yes it will overwritten by the configuration.
DelayValidation shoud be set to true for all tasks which can make trouble, if a Connection Manager is not set well.
July 3rd, 2011 3:12am


