Monday, March 12, 2012

Row Count problem

I've got a table which I know has 10108 rows in (I've looped through the table with some C# code), yet, in Enterprise manager, when i right click and view properties, the ROWS returns 10043 - a difference of 65 rows!

Why is this?

BTW - not that it should make any difference, but its on SQL Server 2000 standard edition.run

select count(*) from tablename

That will give the true result. Then it will either be down to some dodgy stats/code in EM or your code ;)|||I know that! Like I said - I already KNOW how many rows are in the table - that isn't the issue. The issue is why the right click > Properties gives me a different answer. Even if I DROP the table, re-CREATE it and INSERT maybe 50 rows, I still don't get the correct number of rows that I input.|||You didn't explain that at all. You said you've used c# code and that maybe faulty. IF the count(*) is tallying with your c# code then fair enough. Is it?

No comments:

Post a Comment