pgsql: Fix minmax-multi distance for extreme interval values

2023-10-27 Thread Tomas Vondra
Fix minmax-multi distance for extreme interval values When calculating distance for interval values, the code mostly mimicked interval_mi, i.e. it built a new interval value for the difference. That however does not work for sufficiently distant interval values, when the difference overflows the

pgsql: Fix minmax-multi distance for extreme interval values

2023-10-27 Thread Tomas Vondra
Fix minmax-multi distance for extreme interval values When calculating distance for interval values, the code mostly mimicked interval_mi, i.e. it built a new interval value for the difference. That however does not work for sufficiently distant interval values, when the difference overflows the

pgsql: Fix minmax-multi distance for extreme interval values

2023-10-27 Thread Tomas Vondra
Fix minmax-multi distance for extreme interval values When calculating distance for interval values, the code mostly mimicked interval_mi, i.e. it built a new interval value for the difference. That however does not work for sufficiently distant interval values, when the difference overflows the

pgsql: Fix minmax-multi distance for extreme interval values

2023-10-27 Thread Tomas Vondra
Fix minmax-multi distance for extreme interval values When calculating distance for interval values, the code mostly mimicked interval_mi, i.e. it built a new interval value for the difference. That however does not work for sufficiently distant interval values, when the difference overflows the