夢幻之旅

          DEBUG - 天道酬勤

             :: 首頁 :: 新隨筆 :: 聯系 :: 聚合  :: 管理 ::
            671 隨筆 :: 6 文章 :: 256 評論 :: 0 Trackbacks
          select tablespace_name,sum(bytes)/1024/1024/1024 GB
          from dba_data_files group by tablespace_name
          union all
          select tablespace_name,sum(bytes)/1024/1024/1024 GB
          from dba_temp_files group by tablespace_name order by GB;


          select 
          b.
          file_id file_id
          b.tablespace_name, 
          b.bytes, 
          b.maxbytes,
          (b.bytes
          -sum(nvl(a.bytes,0))) used, 
          sum(nvl(a.bytes,0)) unused, 
          sum(nvl(a.bytes,0))/(b.bytes)*100 percentage 
          from dba_free_space a,dba_data_files b 
          where a.file_id=b.file_id 
          group by b.tablespace_name,b.file_id,b.bytes,b.maxbytes
          order by b.file_id;
          posted on 2011-04-19 13:09 HUIKK 閱讀(206) 評論(0)  編輯  收藏 所屬分類: DataBase
          主站蜘蛛池模板: 潮安县| 瑞昌市| 偃师市| 蓝山县| 安溪县| 天津市| 社旗县| 宕昌县| 商都县| 烟台市| 南康市| 孟州市| 金沙县| 潼南县| 红河县| 平武县| 崇仁县| 龙江县| 手游| 万宁市| 微山县| 太仓市| 乌苏市| 长沙县| 寿宁县| 清原| 西充县| 句容市| 六枝特区| 遂川县| 黄龙县| 卢龙县| 巴青县| 滦平县| 金乡县| 蒙自县| 张掖市| 新晃| 伊宁县| 永宁县| 高台县|