首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 数据库 > 其他数据库 >

在SqlServer数据库如何查询某个字段在哪些表中出现过

2012-07-28 
在SqlServer数据库怎么查询某个字段在哪些表中出现过Select a.name as Columns, b.name as TableName from

在SqlServer数据库怎么查询某个字段在哪些表中出现过
Select a.name as Columns, b.name as TableName from syscolumns a
left join sysobjects b on a.id = b.id
Where b.type = 'U' and a.name ='Book_Code' order by b.name
b.type='U' (表),  b.type='V' (视图)

热点排行