CUPUM / nplex

Plateforme de valorisation de petits projets d'architecture et d'aménagement à Montréal.
https://www.nplex.design
4 stars 0 forks source link

Task: Fix `range` pg types collapsing to `empty` when same-bounded #225

Closed iolyd closed 9 months ago

iolyd commented 11 months ago

Task Description

Postgres range types natively collapse to empty when both the lower and upper boundaries are of identical value. While this is semantically correct, it leads to losing any boundary information. We should prevent this by making sure our custom drizzle range type(s) implement toDriver methods that coalesce collapsing ranges to an asymmetrically bounded ([...) or (...]) range that will automatically increment or decrement one of the bounds to ensure a range of at least one-unit in size.

List of actions