dbTalk Databases Forums  

executing DTS package from Stored Procedure

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


Discuss executing DTS package from Stored Procedure in the microsoft.public.sqlserver.dts forum.



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

Default executing DTS package from Stored Procedure - 04-13-2004 , 12:21 PM






Hello Everyone,

I like to know if a DTS package could be executed from
within a stored procedure.
I looked at the SQL Server Books Online and did not find
any help.

Thanks,

--Mitra

Reply With Quote
  #2  
Old   
Sue Hoegemeier
 
Posts: n/a

Default Re: executing DTS package from Stored Procedure - 04-13-2004 , 12:44 PM






The following link will explain a couple of options on
executing the package using T-SQL:
Execute a package from T-SQL
http://www.sqldts.com/default.aspx?210

-Sue

On Tue, 13 Apr 2004 10:21:41 -0700, "mitra fatolahi"
<mitra928 (AT) hotmail (DOT) com> wrote:

Quote:
Hello Everyone,

I like to know if a DTS package could be executed from
within a stored procedure.
I looked at the SQL Server Books Online and did not find
any help.

Thanks,

--Mitra


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

Default Re: executing DTS package from Stored Procedure - 04-13-2004 , 12:44 PM



It most certainly can be yes

Execute a package from T-SQL
(http://www.sqldts.com/default.aspx?210)

--
--

Allan Mitchell MCSE,MCDBA, (Microsoft SQL Server MVP)
www.SQLDTS.com - The site for all your DTS needs.
I support PASS - the definitive, global community
for SQL Server professionals - http://www.sqlpass.org


"mitra fatolahi" <mitra928 (AT) hotmail (DOT) com> wrote

Quote:
Hello Everyone,

I like to know if a DTS package could be executed from
within a stored procedure.
I looked at the SQL Server Books Online and did not find
any help.

Thanks,

--Mitra



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

Default Re: executing DTS package from Stored Procedure - 04-13-2004 , 06:42 PM



On Tue, 13 Apr 2004 10:21:41 -0700, "mitra fatolahi"
<mitra928 (AT) hotmail (DOT) com> wrote:

Quote:
Hello Everyone,

I like to know if a DTS package could be executed from
within a stored procedure.
I looked at the SQL Server Books Online and did not find
any help.
If you schedule the package, you can. You actually run the scheduled
job, not the package.


Reply With Quote
  #5  
Old   
Farhad Raeisi
 
Posts: n/a

Default RE: executing DTS package from Stored Procedure - 04-13-2004 , 09:16 PM



You need to run the DTS using dtsrun command. In your stored procedure use the following

exec master.dbo.xp_cmdshell 'dtsrun /S <servername> /E /N dts_name

which <servername> is your server name or IP address and dts_name is your DTS package name. I hope this solve your problem

Farha
CanadaDBA (AT) yahoo (DOT) ca

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.