以下作品但是返回查看结果:
SELECT COUNT(*),table_name FROM INFORMATION_SCHEMA.COLUMNS Group By table_name
有什么建议么?
注意:MSsql 2005
SELECT t.name,count(c.name) FROM sys.tables t inner join sys.columns c ON t.object_id = c.object_id group by t.name