日期:2025-07-17 14:50:15 人气:1

    A+
热门评论

数据库数据量有多大

查询一张表的总大小(单位MB,包含表的索引和数据,假设表的模式为,表名为): select pg_size_pretty(pg_total_relation_size('.')); 查询表的数据大小(单位MB,不包括索引,假设表的模式为,表名为): select pg_size_pretty(pg_relation_size('.')); 查询分区表所有分区的总大小(单位MB,包含表的索引和数据,假设表的模式为,表名为): select schemaname,tablename,round(sum(pg_total_relation_size(schemaname || '.' || partitiontablename))/1024/1024) "MB" from pg_partitions where schemaname='' and tablename='' group by 1,2; 查询一个Schema下面的所有表的总大小(单位MB,包括索引和数据,假设模式为): select schemaname ,round(sum(pg_total_relation_size(schemaname||'.'||tablename))/1024/1024) "Size_MB" from pg_tables where schemaname='' group by 1; 查询每个数据库的大小(单位 MB): select datname,pg_size_pretty(pg_database_size(datname)) from pg_database;

阅读全文

大数据是什么概念

大数据指无法在一定时间范围内用常规软件工具进行捕捉、管理和处理的数据集合。通过大量的统计了解大家的喜好,想要的东西,从而得到他们想要的,比如精准营销,征信分析,消费分析等等

阅读全文