Hello. I want to know what does RETURN_VALUE mean! I'm stuck at this thing. How to use RETURN_VALUE in a SQL Server stored procedure? thanks..
ASP:
Set cmdDB = Server.CreateObject("ADODB.Command")
With cmdDB
.ActiveConnection = ADOConM
.CommandText = "usp_jaljava_member_select"
.CommandType = adCmdStoredProc
.Parameters.Append .CreateParameter("RETURN_VALUE", adInteger, adParamReturnValue, 0)
.Parameters.Append .CreateParameter("@TLoginName", adVarChar, adParamInput, 15, lcase(TLoginName))
.Parameters.Append .CreateParameter("@TPassword", adVarChar, adParamInput, 20, TPassword)
.Parameters.Append .CreateParameter("@retval", adVarChar, adParamOutput, 50)
' .Parameters.Append .CreateParameter("@TPinCode", adVarChar, adParamInput, 15,TPinCode) .Execute,,adExecuteNoRecords
RetVal = .Parameters("@retval")
Ret = Trim(.Parameters("RETURN_VALUE"))
'Set .ActiveConnection = Nothing
End With
Set cmdDB = Nothing
UTid = RetVal
SQL Server stored procedure:
CREATE PROCEDURE usp_jaljava_member_select
@TLoginName varchar(15),
@TPassword varchar(20),
@retval varchar(50) OUTPUT
--@TPinCode varchar(15)
AS