SELECT '[' + SCHEMA_NAME(t.schema_id) + '].[' + t.name + ']' AS fulltable_name,
SCHEMA_NAME(t.schema_id) AS schema_name,
t.name AS table_name,
i.rows
FROM sys.tables AS t INNER JOIN sys.sysindexes AS i
ON t.object_id = i.id AND i.indid < 2
o
select distinct convert(varchar(30),object_name(a.id)) [Table Name], a.rows from sysindexes a inner join sysobjects b on a.id = b.id
Referencia: http://venkattechnicalblog.blogspot.com/2008/09/list-out-all-tables-and-row-count-in.html
http://geekswithblogs.net/TakeNote/archive/2007/09/22/115537.aspx
No hay comentarios:
Publicar un comentario