Useful code to gather the rowcount of all tables, worth doing a reindex prior to this code
SELECT
SCHEMA_NAME(t1.schema_id) AS [schema],
t1.name AS [table],
i1.rows AS [row_count]
FROM sys.tables AS t1 INNER JOIN
sys.sysindexes AS i1 ON t1.object_id = i1.id AND i1.indid < 2
This is only a preview. Your comment has not yet been posted.
As a final step before posting your comment, enter the letters and numbers you see in the image below. This prevents automated programs from posting comments.
Having trouble reading this image? View an alternate.
Posted by: |