October 21, 2009 at 11:42 pm
I am writing a package that will be writing a file out to a share on the server.
This used to be done with sp_makeWebTask. This made it easy to always have the file saved on the correct server as we would simply use
@Filename = @@servername + @restOfFileName
How using an SSIS package do i dynamically get the server name that a package is running under, store this in a variable and use this servername in the path a file will be written out to?
October 25, 2009 at 7:08 am
winston Smith (10/21/2009)
I am writing a package that will be writing a file out to a share on the server.This used to be done with sp_makeWebTask. This made it easy to always have the file saved on the correct server as we would simply use
@Filename = @@servername + @restOfFileName
How using an SSIS package do i dynamically get the server name that a package is running under, store this in a variable and use this servername in the path a file will be written out to?
You have @[System::MachineName] variable, which contains the machine name under which the package is executing. You can find more information about the other system variables here:
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply