select distinct object_name(id) from syscomments
where id in (select id from sysobjects where type in('V','P'))
and text like '%表名%'
sqlserver 查询当前表被哪些视图引用语句
最新推荐文章于 2024-04-24 16:25:05 发布
select distinct object_name(id) from syscomments
where id in (select id from sysobjects where type in('V','P'))
and text like '%表名%'