Add logic to ignore dropped chunks in hypertable_relation_size

Function hypertable_relation_size includes chunks that were dropped
which causes a failure when looking up the size of dropped chunks.
This patch adds a constraint to ignore dropped chunks when determining
the size of the hypertable.
This commit is contained in:
zcavaliero 2020-02-17 09:30:09 -05:00 committed by Sven Klemm
parent 474db5e448
commit 656bd3f6cc

View File

@ -55,6 +55,7 @@ BEGIN
pg_class pgc,
pg_namespace pns
WHERE h.schema_name = %L
AND c.dropped = false
AND h.table_name = %L
AND c.hypertable_id = h.id
AND pgc.relname = h.table_name