查询表空间使用情况

Select Owner,Tablespace_name,Segment_Name,Segment_Type,Sum(bytes)/1024/1024 sums From Dba_Extents
 where owner='NBCHECK' and Segment_Type='TABLE'
    Group By Owner,Tablespace_name,Segment_Name,Segment_Type
    Order By sums

 

 

 

表空间的大小与用户的配额大小是两种不同的概念。表空间的大小是指实际的用户表空间的大小,而配额大小指的是用户指定使用表空间的的大小

把表空间文件增大,还是出现这个问题,用户在使用表空间的同时使用空间的限额,如果超出限制,就算有空的地方,也不会让用户使用。

遇到ORA-01536错误,首先要查看用户的表空间的限额

   select * from dba_ts_quotas;

   select * from user_ts_quotas;

max_bytes字段-1是代表没有限制,其它值多少就是多少. 

<meta. content="text/html; charset=utf-8" http-equiv="Content-Type"> <meta. content="OneNote.File" name="ProgId"> <meta. content="Microsoft OneNote 12" name="Generator">

dba_ts_quotas :描述所有用户表空间的限额

<meta. content="text/html; charset=utf-8" http-equiv="Content-Type"> <meta. content="OneNote.File" name="ProgId"> <meta. content="Microsoft OneNote 12" name="Generator">

user_ts_quotas :描述当前用户表空间的限额。

如果查询结果中max_bytes字段不为-1,修改为无限制或者指定的大小。

<meta. content="text/html; charset=utf-8" http-equiv="Content-Type"> <meta. content="OneNote.File" name="ProgId"> <meta. content="Microsoft OneNote 12" name="Generator">

不对用户做表空间限额控制:

    GRANT UNLIMITED TABLESPACE TOuser;

这种方式是全局性的。  或者

    alter useruserquota unlimited onuser_tablespace;

 这种方式是针对特定的表空间的.

回收表空间限额控制:

    revoke unlimited tablespace fromuser;

或者

    alter useruserquota 0 onuser_tablespace;

 

 

 

ITPUB个人空间"F6P*Zt%HZ(BGo

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值