Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Administration (2000)
 Is sp_spaceused useful?

Author  Topic 

dbthj
Posting Yak Master

143 Posts

Posted - 2007-10-11 : 10:14:30
If you find sp_spaceused usefull, perhaps you can explain the
terminology and the arithmatic involved in making sense of the results.

One Microsoft doc says something like, "database_size is bigger
than Reserved Plus Space unallocated because it includes logs."
Then it says Reserved and Space Unallocated only report data and
not indexes.

So you'd think size = reserved + unallocated + logs + index size.
Nope. That doesn't add up.

Does "Reserved" mean "allocated"
Does "used" mean data and indexes and logs? Data and Indexes pages?
Does "unallocated" mean "unused"


BOL does not explain any of these terms.
What kind of arithmatic can be used to make sense of the numbers?

Forget for the time-being that SQL 2000 can return a negative
number for space unallocated. That's gotta be a bug.
I'm just trying to understand the terminology and what
arithmatic SHOULD be valid.

In various forums I find procedures and queries that can
give useful results regarding size, but I have a lot of
instances to manage and would prefer to use what's already there
if sense can be made of it.

   

- Advertisement -