Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Problem with a Stored Proc Returning Values

Status
Not open for further replies.

FireFett

Programmer
Mar 31, 2000
42
US
I know its a newbie problem that much I do know but not sure what I am doing wrong

I have three output parameters defined
outUserID
outUserName
outPass

The select statment that I want to execute is:

Select UserID, UserName, Pass from tbl_security

Looking at the documentation the Stored Proc SQL Statement

Should be the following:

SELECT UserID INTO outUserID, UserName INTO outUserID, Pass INTO outPASS FROM tbl_security;

but this doesn't work and says the UserName varialbe is not declared. What am I doing wrong?
 
The manual isn't the best yet for documentation on stored procs,


DELIMITER //
CREATE PROCEDURE getstuff()
LANGUAGE SQL
NOT DETERMINISTIC
COMMENT 'get info for users'
BEGIN
SELECT
UserID,UserName,Pass
FROM
tbl_security;

END;
//
DELIMITER ;


______________________________________________________________________
There's no present like the time, they say. - Henry's Cat.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top