如何在存储过程中创建多个输出参数
答案 0 :(得分:1)
即使你的问题不是很简洁,我也会试着回答,正如Tom H所说的那样,你似乎并没有付出太多努力。
CREATE PROCEDURE [dbo].[Conv05_InsertAgents]
@InsertedDog AS INT OUTPUT,
@InsertedCat AS INT OUTPUT
AS
BEGIN
INSERT INTO DOG (Name, Color) VALUES ('Fifi', 'White')
SET @InsertedDog=@@ROWCOUNT
INSERT INTO Cat(Name, Color) VALUES ('Fofo', 'Black')
SET @InsertedCat=@@ROWCOUNT
END