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
 General SQL Server Forums
 New to SQL Server Programming
 returning values from sp

Author  Topic 

sujeethbala2110
Starting Member

29 Posts

Posted - 2006-09-13 : 05:17:21
hi
can i return value(bool) from a sp based on the result and receive in my vb code.


suji

chiragkhabaria
Master Smack Fu Yak Hacker

1907 Posts

Posted - 2006-09-13 : 05:21:57
yeah, you can do it, but setting output parameter to your sp.

Create proc test
(
@flag bit output
)
As
Set @flag = 1


Chirag
Go to Top of Page

SwePeso
Patron Saint of Lost Yaks

30421 Posts

Posted - 2006-09-13 : 05:22:32
Make the return value as a paramater as InputOutput.


Peter Larsson
Helsingborg, Sweden
Go to Top of Page

sujeethbala2110
Starting Member

29 Posts

Posted - 2006-09-13 : 05:57:10
thanks

suji
Go to Top of Page

Kristen
Test

22859 Posts

Posted - 2006-09-13 : 06:27:25
"Make the return value as a paramater as InputOutput"

Not to be confused with the Sproc's RETURN value ... which my preference would be to reserve for the @@ERROR value

Kristen
Go to Top of Page
   

- Advertisement -