Opened 14 years ago

Closed 14 years ago

#378 closed defect (fixed)

Change ST_Equals to use && instead of ~=

Reported by: robe Owned by: pramsey
Priority: medium Milestone: PostGIS 1.5.0
Component: postgis Version: master
Keywords: Cc:

Description

This is sort of getting to what Mark was saying. The behavior is borderline wrong, but not for the reason I think Mark was complaining about.

http://postgis.refractions.net/pipermail/postgis-users/2010-January/025551.html

It is more an issue with soft upgrade.

We can't change the behavor of ~= with soft upgrade because we can't drop operators. That means people upgrading depending on which version they started off with are going to have some ~= with RECHECK and some with not RECHECK. Which will make it either behave like a bounding box equality check or a ST_OrderingEquals check.

~= with RECHECK is the wrong behavior for ST_Equals because a true or false to that answer doesn't tell you if _ST_Equals will be true or false. Because ST_EQUALS follows DE-IM which means geometries with flipped coordinates will be considered _ST_Equals, but fail the RECHECKED ~= and geometries that are invalid but binary equal can pass the ~= test but fail the _ST_Equals.

Until we can figure out how to deal with the

~= inconsistent behavior of installs — make this an && test. Which will slow it down a bit I guess.

Change History (1)

comment:1 by pramsey, 14 years ago

Resolution: fixed
Status: newclosed

OK, I can buy that. Done at r5118

Note: See TracTickets for help on using tickets.