I have a stored procedure which returns a temporary table as well as the output parameter. I am returning values from SP
CREATE PROCEDURE [dbo].[procedure_name]
(
@Id int
@ReturnCode int output
)
AS
BEGIN
Create table #tbl_temp (
i INT identity,
TestId INT
)
Insert into table #tbl_temp -- Inserting Records
Select from table #tbl_temp -- This resultSet will be my output
SET @ReturnCode = 9 // some int value
select * from #tbl_temp // returning the temporary table
END
In Classic ASP, To get the tempTable, the code written is like this
rs.open sp.execute()
In the above case, I cannot get the value of the "@ReturnCode".
I need both the values. How should I achieve this?