Store procedures can return value using a return statement in the store procedure
you can do something like this
create PROCEDURE dbo.test1
(
@iID int
)
AS
BEGIN
SET NOCOUNT ON;
Declare @iNewId int
set @iNewId = @iID + 1
return @iNewId
END
declare @iT int
exec @iT = dbo.test1 6
print @iT
Tuesday, October 16, 2007
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment