Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 SSIS and Import/Export (2005)
 Referencing a Connection's ConnectionString prop.

Author  Topic 

mpopkin
Starting Member

3 Posts

Posted - 2008-06-26 : 13:59:36
Hi All,

I have dynamically set the filename (ConnectionString) for a flat file connection in an expression. It is correctly outputting to the dynamically generated filename.

I need to use this filename in the Arguments property of an Execute Process Task. Is there a way to reference the ConnectionString property of the flat file connection?

Can I obtain this in an expression for the Execute Process Task?

Any help would be greatly appreciated.

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2008-06-26 : 14:26:57
You can try to use your expression for building the filename to a package-var. Then use this var in your flatfile connection expression and maybe you can use this var in your process task?

greetings
Webfred

There are 10 types of people in the world: Those who understand binary, and those who don't...
Go to Top of Page

mpopkin
Starting Member

3 Posts

Posted - 2008-06-30 : 14:17:30
Thanks Webfred!

It looks plausible. I will just need to figure out how to dynamically change a package variable in SSIS with an expression.

I need it to remain constant for the duration of the package execution as the filename is based on current date and time.

Go to Top of Page

webfred
Master Smack Fu Yak Hacker

8781 Posts

Posted - 2008-07-01 : 16:01:35
Hi mpopkin,
you can create the var and then in the property of the var you can set the expression.
This expression is only executed one time at start of your package.
So you can use it for the duration of the package execution, it will not change its value.
greetings
Webfred

There are 10 types of people in the world: Those who understand binary, and those who don't...
Go to Top of Page

mpopkin
Starting Member

3 Posts

Posted - 2008-07-02 : 14:46:32
Thanks again!

I had just figured out how to use the expression on the variable, but I didn't know if it would set once or if it would run the expression each time the variable was referenced.

That's the detail I needed!
Go to Top of Page
   

- Advertisement -