No SELECT (casewhena. colorder1thend. nameelseend) Table Name,. colorder field number,. name field name, (casewhenCOLUMNPROPERTY (. id,. name, IsIdentity) 1then √ elseend) ID, (casewhen (SELECTcount (*) FROMsysobjectsWHERE (name
No SELECT (case when. colorder = 1 then d. name else ''end) Table name,. colorder field number,. name field name, (case when COLUMNPROPERTY (. id,. name, 'isidentity ') = 1 then' √ 'else' end) identifier, (case when (SELECT count (*) FROM sysobjects WHERE (name
<无>
SELECT (case when. colorder = 1 then d. name else ''end) Table name,. colorder field number,. name field name, (case when COLUMNPROPERTY (. id,. name, 'isidentity ') = 1 then' √ 'else' end) identifier, (case when (SELECT count (*) FROM sysobjects WHERE (name in (SELECT name FROM sysindexes WHERE (id =. id) AND (indid in (SELECT indid FROM sysindexkeys WHERE (id =. id) AND (colid in (SELECT colid FROM syscolumns WHERE (id =. id) AND (name =. name) AND (xtype = 'pk')> 0 then' √ 'else' end) primary key, B. name type,. length occupies the number of bytes, COLUMNPROPERTY (. id,. name, 'precision ') as length, isnull (COLUMNPROPERTY (. id,. name, 'Scale'), 0) as decimal places, (case when. isnullable = 1 then' √ 'else' end) Allow null, isnull (e. text, '') default value, isnull (g. [value], '') AS field description FROM syscolumns a left join policypes B on. xtype = B. xusertype inner join sysobjects d on. id = d. id and d. xtype = 'U' and d. name <> 'dtproperties' left join syscomments e on. cdefault = e. id left join sysproperties g on. id = g. id AND. colid = g. smallid order by. id,. colorder