WEB开发网
开发学院数据库MySQL 从动态SQL中返回值 阅读

从动态SQL中返回值

 2007-11-11 16:09:27 来源:WEB开发网   
核心提示: declare @TransactorID intset @TransactorID=0print(@TransactorID)--exec sp_executesql N'select @TransactorID=68 ',N'@TransactorID i


   
declare @TransactorID int
set @TransactorID=0
print(@TransactorID)
--exec sp_executesql N'select @TransactorID=68 ',N'@TransactorID int ',@TransactorID
exec sp_executesql N'select @TransactorID=5 ',N'@TransactorID int out ',@TransactorID out
print(@TransactorID)

Tags:动态 SQL 返回

编辑录入:coldstar [复制链接] [打 印]
赞助商链接