您的位置:首页 > 博客中心 > 数据库 >

sql server 查看列备注、类型、字段大小

时间:2022-03-10 18:12

select 
列名 =  a.name
,类型 = c.name
,长度 = columnproperty(a.id,a.name,‘precision‘)
,备注 = g.value
from syscolumns a
left join sysobjects b on a.id=b.id
left join systypes c on a.xusertype = c.xusertype
left join sysproperties g on a.id =g.id and a.colid =g.smallid
where b.name = ‘TBL_ORD_MAIN‘

sql server 查看列备注、类型、字段大小,布布扣,bubuko.com

热门排行

今日推荐

热门手游