Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 Import/Export (DTS) and Replication (2000)
 getting stored procedure output parameter using DTS

Author  Topic 

AskSQLTeam
Ask SQLTeam Question

0 Posts

Posted - 2003-01-31 : 08:53:27
Ichad writes "I have 2 problems when using DTS.

First:
I have an Execute SQL task in a DTS package that calls a stored procedure that have output parameter.

exec sp1 ?, ?

The first parameter is input parameter that comes from a global variable, and the second one is the output parameter that is assigned to another global variable.
The problem is I can't assign the output parameter of the stored procedure to the global variable.

Second:
Also related to the above stored procedure.
Suppose, the stored procedure returns value 0 or 1.
How can I capture the return value and assign it to a global variable.
I need that value to check whether the sp is succesful or not.

Thank's for the answer."

ValterBorges
Master Smack Fu Yak Hacker

1429 Posts

Posted - 2003-01-31 : 08:59:07
Take a look at nr's site under dts and you will find an example.
Another thing to try would be sp_executesql which he also has an example of.

www.nigelrivett.com

Go to Top of Page
   

- Advertisement -