当前位置: 代码迷 >> Sql Server >> 容易的存储过程,但是总是出错。请高手了
  详细解决方案

容易的存储过程,但是总是出错。请高手了

热度:95   发布时间:2016-04-24 23:08:03.0
简单的存储过程,但是总是出错。请高手了。
declare @sql varchar(1000)
set @sql='delete from users 
where userid=1 and tagid in (23)
'
exec @sql

消息 2812,级别 16,状态 62,第 5 行
找不到存储过程 'delete from users 
where userid=1 and  tagid in (23)
'。

------解决方案--------------------
exec(@sql)
  相关解决方案