June 20, 2005 at 2:23 pm
I have SQL Server 2000 (SP 3). Using EM, I double click on a table and get the record count. Then using QA, I perform a Select * From TableName and get another record count. Why is this?
Thanks in advance, Kevin
June 20, 2005 at 2:32 pm
Select count(*) opens the table and counts all the rows.
EM uses the information kept in the sysIndexes system table. This information is not kept up to date 100% of the time for performance reasons. You can run sp_updatestats to correct this problem (for the time being).
June 20, 2005 at 3:32 pm
If you have a very dynamic table QA or EM may be grabbing the table info from cache.
June 21, 2005 at 1:57 am
In EM, a double click on a table gives a rough estimation of the record count.
Using SELECT COUNT(*) gives you the correct answer (the same as in QA).
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply