dbTalk Databases Forums  

Getting the Server and Database Name from the Command Line

microsoft.public.sqlserver.dts microsoft.public.sqlserver.dts


Discuss Getting the Server and Database Name from the Command Line in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
David Borgo
 
Posts: n/a

Default Getting the Server and Database Name from the Command Line - 11-18-2004 , 10:16 AM






I am running a DTS project that calls 10 execute packages in a
workflow to create flat ASCII files from tables.

I know that in order to change the Source Server and Database name in
the Microsoft OLE DB Provider for SQL Server, that I will need to pass
in a global variable, but I am clueless on how to use ActiveX to
write VB code to accomplish this.

I'm sure some of you have done this. Can anyone help me out?

Thanks

Reply With Quote
  #2  
Old   
Allan Mitchell
 
Posts: n/a

Default Re: Getting the Server and Database Name from the Command Line - 11-20-2004 , 01:40 AM






Your subject line suggests you are doing this on the cmdline in which case using SQL Server 2000 you would use the /A argument to
the DTSRUN executable
Inside the package you would just set the correct properties to the correct variable.

In VB, which is what the body f your post suggests you are using then I would be inclined to use the object model to grab the
package and then set the properties in code.

--

Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
www.Konesans.com


"David Borgo" <davidborgo (AT) yahoo (DOT) com> wrote

Quote:
I am running a DTS project that calls 10 execute packages in a
workflow to create flat ASCII files from tables.

I know that in order to change the Source Server and Database name in
the Microsoft OLE DB Provider for SQL Server, that I will need to pass
in a global variable, but I am clueless on how to use ActiveX to
write VB code to accomplish this.

I'm sure some of you have done this. Can anyone help me out?

Thanks



Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.