Closed NikolayS closed 5 years ago
At least one reason hides here:
select 'Forced Checkpoints', (select round(100.0 * checkpoints_req::numeric / nullif((checkpoints_timed + checkpoints_req), 0), 1)::text || '%' from pg_stat_bgwriter)
union all
Ways to resolve:
nullif(..., 0)
and return NULL
, orcase when
... and return '0'