greenplum查看表和库的⼤⼩查看表的⼤⼩
select pg_size_pretty(pg_relation_size('tb_cfg_city'));
查看库的⼤⼩
select pg_size_pretty(pg_total_relation_size('tb_cfg_city'));
greenplum数据库查看某个数据库的⼤⼩
select pg_size_pretty(pg_database_size('ltjt_dev'));
查看所有库的⼤⼩
select datname,pg_size_pretty(pg_database_size(datname))from pg_database;
查看数据分布情况
select gp_segment_id,count(*)from tb_cfg_city group by gp_segment_id order by1;
查看磁盘空间
select dfhostname, dfspace,dfdevice from gp_toolkit.gp_disk_free order by dfhostname;
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系QQ:729038198,我们将在24小时内删除。
发表评论