G
Guest
Hello,
I have a stored procedure that returns a value but does not select any rows as shown below
How can I access the value of this return value from the database using datasets or dataadapters.
Thanx in advance
Geri
rocedure in question
CREATE PROCEDURE SPSelectUserID as
DECLARE @USERNAME varchar(50)
DECLARE @USERID int
EXEC SPSelectUserLogin @USERNAME = @USERNAME OUTPUT
SELECT @USERID = UserID FROM JobControl WHERE UserName = @USERNAME
RETURN @USERID
I have a stored procedure that returns a value but does not select any rows as shown below
How can I access the value of this return value from the database using datasets or dataadapters.
Thanx in advance
Geri
rocedure in question
CREATE PROCEDURE SPSelectUserID as
DECLARE @USERNAME varchar(50)
DECLARE @USERID int
EXEC SPSelectUserLogin @USERNAME = @USERNAME OUTPUT
SELECT @USERID = UserID FROM JobControl WHERE UserName = @USERNAME
RETURN @USERID