DECLARE @j nvarchar(120),
@sql AS NVARCHAR(100),
@i AS INT;
SET @sql = N' SET @p = 11 set @stmt=''23112'' ';
EXEC sp_executesql @sql, @params = N'@p AS INT OUTPUT,@stmt AS Nvarchar(12) OUTPUT', @p = @i OUTPUT,@stmt=@j output
SELECT @i
select @sql
select @j
执行sql命令,返回参数值,怕忘记了,记录一下
最新推荐文章于 2021-01-19 17:25:30 发布