dbTalk Databases Forums  

run DTS via .net

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


Discuss run DTS via .net in the microsoft.public.sqlserver.dts forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
sophie.belan@eur.crowncork.com
 
Posts: n/a

Default run DTS via .net - 12-04-2003 , 11:20 AM






Hello,

An application .Net has to run a DTS package.
This DTS package uses a step as followed:
Execute SQL Task : execute a stored procedure with
parameters.

The problem is that the parameters of the stored procedure
are using global variables, and .Net encounters some
problems with them :
exec myStoredProcedure ?,? => failure

If we remove the Global Variables from the DTS package
Properties, and hard code the parameters, it works :
exec myStoredProcedure 10, 2003 => success

But in any case, the DTS runs successfully in Entreprise
Manager with or without any global variables.

Thanks for your reply,
Regards,
Sophie BELAN


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

Default Re: run DTS via .net - 12-04-2003 , 12:47 PM






How are you calling the package ? Are you passing in values to the package
for the Global Variables and when you do this through .Net it fails but in
Designer it works?

Have a look at this

DTS Global Variables and Visual Basic .Net
(http://www.sqldts.com/default.aspx?265)

--
--

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

"sophie.belan (AT) eur (DOT) crowncork.com" <anonymous (AT) discussions (DOT) microsoft.com> wrote
in message news:012d01c3ba8a$f7d2daf0$a301280a (AT) phx (DOT) gbl...
Quote:
Hello,

An application .Net has to run a DTS package.
This DTS package uses a step as followed:
Execute SQL Task : execute a stored procedure with
parameters.

The problem is that the parameters of the stored procedure
are using global variables, and .Net encounters some
problems with them :
exec myStoredProcedure ?,? => failure

If we remove the Global Variables from the DTS package
Properties, and hard code the parameters, it works :
exec myStoredProcedure 10, 2003 => success

But in any case, the DTS runs successfully in Entreprise
Manager with or without any global variables.

Thanks for your reply,
Regards,
Sophie BELAN




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.