Oracle DB , 计算各个用户/schema 的磁盘占用空间
http://www.dba-oracle.com/t_find_size_schema.htm
Question: How do I find the size of a schema in my database?
Answer: It depends on how you define "size". If you want the total disk space consumed by the schema (including indexes, tablespace free space), then the SQL query is quite simple:
select owner, sum(bytes)/1024/1024/1024 schema_size_gig from dba_segments group by owner;
If you just want the size of the schema in terms of the space consumed by table rows, you would use a different query to calculate the schema size:
select sum(bytes)/1024/1024/1024 as size_in_gig, segment_type from dba_segments where owner='SCOTT' group by segment_type;
Drop Table 之后,如果空间不能回收,需要执行西面语句
清除当前用户的回收站:purge recyclebin;
清除所有用户的回收站:purge dba_recyclebin;
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· 开发者必知的日志记录最佳实践
· SQL Server 2025 AI相关能力初探
· Linux系列:如何用 C#调用 C方法造成内存泄露
· AI与.NET技术实操系列(二):开始使用ML.NET
· 记一次.NET内存居高不下排查解决与启示
· 阿里最新开源QwQ-32B,效果媲美deepseek-r1满血版,部署成本又又又降低了!
· 开源Multi-agent AI智能体框架aevatar.ai,欢迎大家贡献代码
· Manus重磅发布:全球首款通用AI代理技术深度解析与实战指南
· 被坑几百块钱后,我竟然真的恢复了删除的微信聊天记录!
· AI技术革命,工作效率10个最佳AI工具