Skip to content

Commit 70d845c

Browse files
committed
better output b1
1 parent eea4998 commit 70d845c

File tree

1 file changed

+7
-7
lines changed

1 file changed

+7
-7
lines changed

sql/b1_table_estimation.sql

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -65,13 +65,13 @@ with step1 as (
6565
-- AND tblpages*((pst).free_percent + (pst).dead_tuple_percent)::float4/100 >= 1
6666
)
6767
select
68-
case is_na when true then 'TRUE' else '' end as is_na,
69-
coalesce(nullif(schema_name, 'public') || '.', '') || table_name as table,
70-
pg_size_pretty(real_size::numeric) as size,
71-
pg_size_pretty(extra_size::numeric)::text || ' (' || round(extra_ratio::numeric, 2)::text || '%)' as extra_estimated,
72-
pg_size_pretty(bloat_size::numeric)::text || ' (' || round(bloat_ratio::numeric, 2)::text || '%)' as bloat_estimated,
73-
fillfactor,
74-
pg_size_pretty((real_size - bloat_size)::numeric) as live
68+
case is_na when true then 'TRUE' else '' end as "Is N/A",
69+
coalesce(nullif(schema_name, 'public') || '.', '') || table_name as "Table",
70+
pg_size_pretty(real_size::numeric) as "Size",
71+
'~' || pg_size_pretty(extra_size::numeric)::text || ' (' || round(extra_ratio::numeric, 2)::text || '%)' as "Extra",
72+
'~' || pg_size_pretty(bloat_size::numeric)::text || ' (' || round(bloat_ratio::numeric, 2)::text || '%)' as "Bloat_estimated",
73+
'~' || pg_size_pretty((real_size - bloat_size)::numeric) as "Live",
74+
fillfactor
7575
\if :postgresdba_extended
7676
,
7777
real_size as real_size_raw,

0 commit comments

Comments
 (0)