Hi,
Some time ago I’ve provided some details with the issues we face when trying to use GIST and partitioning at the same time in the postgresql-general mailing list:
We decided to go with the solution to partition our table by:
RANGE (‘2100-01-01' <-> operation_date).
While it (somewhat) solves partition pruning issues described above there is another problem:
It is impossible to create a unique constraint on the partitioned table.
So now we cannot use INSERT … ON CONFLICT (…) DO UPDATE
My question to hackers:
Would it be feasible to implement ORDER BY column GIST index (only) scan for types with total order and sensible greatest and least values?
Thanks,
Michal