SQL中通过表字段名称查询对应表名称

Posted on 2021-05-28 15:34  逸竹  阅读(468)  评论(0)    收藏  举报

select * from sys.objects as a where a.object_id in(select [OBJECT_ID] from sys.all_columns where name ='IsAccount')
and a.type='U'

博客园  ©  2004-2025
浙公网安备 33010602011771号 浙ICP备2021040463号-3