dbTalk Databases Forums  

Accessing DTS properties via TSQL

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


Discuss Accessing DTS properties via TSQL in the microsoft.public.sqlserver.dts forum.



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

Default Accessing DTS properties via TSQL - 12-29-2006 , 02:25 PM






Can anyone tell me how to access DTS properties (such as global
variable values) via TSQL?

Examples would be nice.

Thanks


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

Default Re: Accessing DTS properties via TSQL - 12-29-2006 , 03:28 PM






Probably not in the way you would want but you need to look up the
sp_OA* family of stored procedures


--


Allan Mitchell
http://wiki.sqlis.com | http://www.sqlis.com | http://www.sqldts.com |
http://www.konesans.com




"BLS" <bigluckysmile (AT) gmail (DOT) com> wrote


Quote:
Can anyone tell me how to access DTS properties (such as global
variable values) via TSQL?

Examples would be nice.

Thanks


Reply With Quote
  #3  
Old   
Simon Sabin
 
Posts: n/a

Default Re: Accessing DTS properties via TSQL - 12-31-2006 , 04:45 PM



Hello BLS,

DTS doesn't run within TSQL. Are you trying to execute some TSQL from within
a DTS package and have the TSQL use some global variable.

If so you can set the SQL in your execute sql task from an activex script
component. In here you can build the TSQL with the value of the global variable.


Simon Sabin
SQL Server MVP
http://sqlblogcasts.com/blogs/simons


Quote:
Can anyone tell me how to access DTS properties (such as global
variable values) via TSQL?

Examples would be nice.

Thanks




Reply With Quote
  #4  
Old   
BLS
 
Posts: n/a

Default Re: Accessing DTS properties via TSQL - 01-01-2007 , 03:09 PM




Simon Sabin wrote:
Quote:
Hello BLS,

DTS doesn't run within TSQL. Are you trying to execute some TSQL from within
a DTS package and have the TSQL use some global variable.

If so you can set the SQL in your execute sql task from an activex script
component. In here you can build the TSQL with the value of the global variable.


What I would like to do is access a DTS global variable inside a TSQL
task. I'd like to set its value, etc, only not via activex but using
TSQL.



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

Default Re: Accessing DTS properties via TSQL - 01-01-2007 , 03:23 PM



Using the ExecuteSQL task you can assign values from a SQL Statement to
Global Variables.

Is this what you want?

--


Allan Mitchell
http://wiki.sqlis.com | http://www.sqlis.com | http://www.sqldts.com |
http://www.konesans.com




"BLS" <bigluckysmile (AT) gmail (DOT) com> wrote


Quote:
Simon Sabin wrote:
Hello BLS,

DTS doesn't run within TSQL. Are you trying to execute some TSQL from within
a DTS package and have the TSQL use some global variable.

If so you can set the SQL in your execute sql task from an activex script
component. In here you can build the TSQL with the value of the global variable.



What I would like to do is access a DTS global variable inside a TSQL
task. I'd like to set its value, etc, only not via activex but using
TSQL.


Reply With Quote
  #6  
Old   
BLS
 
Posts: n/a

Default Re: Accessing DTS properties via TSQL - 01-01-2007 , 07:21 PM




Allan Mitchell wrote:
Quote:
Using the ExecuteSQL task you can assign values from a SQL Statement to
Global Variables.

Is this what you want?
Yes. Do you know the syntax for how to assign values to DTS Global
Variables in that way?



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

Default Re: Accessing DTS properties via TSQL - 01-02-2007 , 04:47 PM



Have a look at this article

http://www.developmentnow.com/g/103_...After-Move.htm

--


Allan Mitchell
http://wiki.sqlis.com | http://www.sqlis.com | http://www.sqldts.com |
http://www.konesans.com




"BLS" <bigluckysmile (AT) gmail (DOT) com> wrote


Quote:
Allan Mitchell wrote:
Using the ExecuteSQL task you can assign values from a SQL Statement to
Global Variables.

Is this what you want?

Yes. Do you know the syntax for how to assign values to DTS Global
Variables in that way?


Reply With Quote
  #8  
Old   
BLS
 
Posts: n/a

Default Re: Accessing DTS properties via TSQL - 01-02-2007 , 05:17 PM




Thanks! I believe that is exactly what I was looking for.

Much appreciated.


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.