select distinct object_name(id) from syscomments where id in (select id from sysobjects where type in('V','P'))
and text like '%表名%'
SQL检索在视图或者存储过程中有没有使用当前表
最新推荐文章于 2022-10-17 14:32:35 发布
select distinct object_name(id) from syscomments where id in (select id from sysobjects where type in('V','P'))
and text like '%表名%'