zoukankan      html  css  js  c++  java
  • sql 获取字段描述信息

     SELECT
                        ID = newid(),
                        字段名= convert(varchar(100), a.name),
                        表名= convert(varchar(50), d.name ),
                        库名= 'WEPM_OA',
                        字段说明=convert(varchar(50), isnull(g.[value],'')),
                        字段说明=convert(varchar(50), isnull(g.[value],''))
                        FROM dbo.syscolumns a
                        left join dbo.systypes b on a.xusertype=b.xusertype
                        inner join dbo.sysobjects d on a.id=d.id and d.xtype='U' and d.name<>'dtproperties'
                        left join dbo.syscomments e on a.cdefault=e.id
                        left join sys.extended_properties g on a.id=g.major_id and a.colid=g.minor_id
                        left join sys.extended_properties f on d.id=f.major_id and f.minor_id=0
                        where d.name ='Supplier'

  • 相关阅读:
    [代码]codeforces 150c Smart Cheater
    [存档]Young Tableau
    [转载][毁童年]种太阳
    [转载]教练,我也想再要一个同桌
    静夜
    CodeProject每日精选: Applications
    设计模式 装饰模式(Decorator) 精选经验合集
    槟榔味儿办公室
    盗不盗非常盗
    月末之周末
  • 原文地址:https://www.cnblogs.com/cxlings/p/2531128.html
Copyright © 2011-2022 走看看