日期:2014-05-17 浏览次数:20733 次
Create proc P_AA
as
begin
declare @ID int
EXEC P_BB @ID OUT
print @ID
end
GO
create proc P_BB
@re int out
as
begin
set @re=600
return 1
END
GO
exec P_AA
Create proc B(@id int output)
as
begin
declare @num int
set @num=1
set @id=@num
end
GO
CREATE proc A
as
begin
declare @ID int
set @ID=999--怎么把B中的@num的值,赋值给A中的ID@num的值
exec dbo.b @id OUTPUT
print @ID
end
-------------------------
GO