码迷,mamicode.com
首页 > 数据库 > 详细

Oracle查看所有用户占用的表空间

时间:2019-06-18 21:42:13      阅读:188      评论:0      收藏:0      [点我收藏+]

标签:HERE   des   mic   select   tab   obj   com   order   sum   

SELECT OWNER as "用户名", sum(BYTES) / 1024 / 1024 / 1024 as "所有表的大小(GB)"
  FROM DBA_SEGMENTS
 WHERE SEGMENT_NAME in (select t2.OBJECT_NAME
                          from dba_objects t2
                         where t2.OBJECT_TYPE = 'TABLE')
 group by OWNER order by 2 desc

技术图片

Oracle查看所有用户占用的表空间

标签:HERE   des   mic   select   tab   obj   com   order   sum   

原文地址:https://www.cnblogs.com/xianyao/p/11047748.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!