sql_language thread: get null after an 1st call to stored proc, OK after 2nd call
hi,
I have a store procedure which update and return a field ("seq")
alter proc usp_MSAgetSeqCUR @ID varchar (10)
as
-- here I have a code that create @curSeq --
-- update
update msaStatus
set seq = @curSeq
where ID = @id
-- return seq
select @curSeq as "seq"
GO
I retrieve seq from my ASP
seqStr = "EXEC usp_MSAgetSeqCUR @ID = '" & ID & "'"
dim rst, seq
set rst = server.CreateObject ("ADODB.recordset")
set rst = oConn.Execute (seqStr)
Even though seq has been updated after the procedure is called, the
value of the rst("Seq") is "null". But if I refresh the page and run it
second time, I get the correst value in rst("seq"). Any idea why?
-ann