Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
/*Call procedure*/
create procedure proc1
as
/*Declare the output parameter*/
declare @result int
exec proc2 @result output
print @result
go
/*Actual procedure*/
Create procedure proc2 @paramout int output
as
/*Do something*/
SET @paramout=1
go
exec proc1
create procedure usp_generateid @Addrid int,@hubid int
as
/*Do something */
Declare @outaddr int
IF @addriD>@hubid
BEGIN
SET @outaddr=999
END
ELSE
BEGIN
SET @outaddr=888
END
RETURN @outaddr /*Return the value using RETURN */
GO
/*Call Procedure*/
DECLARE @hubid int,
@addrrid int,
@OutAddrId int
/*need to declare @OutAddrId this holds the result*/
/*Assign values */
SELECT @addrrid=11,@hubid=9
EXECUTE @OutAddrId = usp_generateid @addrrid,@HubId
PRINT @OutAddrId