Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Total Bytes Used for a Schema

Status
Not open for further replies.

tekdudedude

Technical User
Sep 29, 2007
79
Hello,

What is the easiest way to determine the total bytes used for a schema?

A schema's usage can be capped via a quota so you would think this value should be stored somewhere easy to get to.

Thanks,

TD
 
TekDude said:
A schema's usage can be capped via a quota
To be precise, quota for schemas is for a specific tablespace, so if you wish to see your user's consumption against quota budget for each tablespace for which the user has quota, then an alternate to Dagon's excellent query is:
Code:
select tablespace_name,bytes,max_bytes
from user_ts_quotas;

TABLESPACE_NAME                     BYTES  MAX_BYTES
------------------------------ ---------- ----------
DATA1                             5636096         -1
DATA2                            11075584          0
SYSTEM                              16384          0
the value of "-1" means that on that particular tablespace, the user has "unlimited" quota.

[santa]Mufasa
(aka Dave of Sandy, Utah, USA)
[I provide low-cost, remote Database Administration services: www.dasages.com]
 
...And I should clarify about the "0" values, as well: If someone consumes space in a tablespace for which quota is zero, then that means that the user also has the "UNLIMITED TABLESPACE" privilege (such as a DBA, which is true in the example, above).

[santa]Mufasa
(aka Dave of Sandy, Utah, USA)
[I provide low-cost, remote Database Administration services: www.dasages.com]
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top