SQL server 查询当前数据库所有表的行数
SELECT OBJECT_NAME(ii.id) TableName ,rows FROM sysindexes ii INNER JOIN sysobjects oo ON ( oo.id = ii.id AND oo.xtype = 'U ') WHERE ii.indid < 2 ORDER BY rows desc ;
SELECT OBJECT_NAME(ii.id) TableName ,rows FROM sysindexes ii INNER JOIN sysobjects oo ON ( oo.id = ii.id AND oo.xtype = 'U ') WHERE ii.indid < 2 ORDER BY rows desc ;