遍历SQL SERVER中所有存储过程和触发器

如果需要查找某个存储过程或触发器中是否含有某段文本(比如:你想知道有哪些存储过程操作了某个表)

可以这么写

select name 
from sysobjects o, syscomments s 
where o.id = s.id 
and text like '%text%' 

猜你喜欢

转载自www.cnblogs.com/songr/p/9020081.html
今日推荐