Hi,
i have inherited a SSIS project that was left unfinished by a previous developer. One thing i notice with it is that all the flat file sources in the connection manager have hardcoded paths for the ConnectionString property. I would like to change this so that at least the path, and if possible the file name, are dynamic - i.e. they are determined either by parameters passed into the package when it is run or they are contained within a config file.
Is this possible? Can anyone supply a link to an article or tutorial specifically covering this?
Many thanks
Hi Sluggy
It's simple.
1) Create a Variable called SourceFolder of Package Scope
2) Choose the Value Property of SourceFolder Variable while Setting Package Configuration.
Now it's ready for use in expression.
3) In the Expression builder for Flat File Connection Manager, choose ConnectionString property for the flat file and use the following expression: [User:ourceFolder] + "\FileName.txt"
Thanks
Subhash Subramanyam
没有评论:
发表评论