[postgis-devel] Recheck on Points broken

Regina Obe lr at pcorp.us
Tue Jan 3 04:54:48 PST 2017


>> Anyrate if there is nothing that can be done about ensuring index 
>> distance is always less or equal to actual distance

> I remember we were all happy about having *real* distance with a more recent PostgreSQL. If that's not the case (as the user reports) we should try to find a way to provide both mechanisms. 
> Two different operators, maybe ?
> --strk;

We've already got two different operators.  We have <#> which doesn't use recheck and that's what I told the user to use, until we resolve this.

The thing is the <-> I think pretty much for all reasonable purposes returns the right order for points (and in fact in this case yields the same value and <-> I think in all cases it will).  

So it's just the float4/float8 mess why it screws up and it Errors noisily in PostgreSQL land where we cannot control.

I hate telling people to if you have point / point use <#> and if you have others you can safely use  <->.  That's sooo unfriendly.

I think the best thing is just to not have point-point checks use recheck.  Can we do that easily? That's what PostgreSQL point/point does.
That way we don't fall into the PostgreSQL box trap of 

"Hey -- how come your index distance is bigger than your computed distance.  What kind of monster are you? Screw you!"

Thanks,
Regina




More information about the postgis-devel mailing list