There are two methods of determining equality in PostGIS.
Obviously these two methods work different, but the docs on
ST_Equals are not clear why,
Returns TRUE if the given Geometries are "spatially equal". Use this for a 'better' answer than '='. Note by spatially equal we mean ST_Within(A,B) = true and ST_Within(B,A) = true and also mean ordering of points can be different but represent the same geometry structure. To verify the order of points is consistent, use ST_OrderingEquals (it must be noted ST_OrderingEquals is a little more stringent than simply verifying order of points are the same).
This seems to mean there is two criterion for
ST_Equals, and that is that
ST_Within(A,B) = true
ST_Within(B,A) = true
However, that ordering of points does not matter with
ST_Equals. Presumably, that would matter with the equal operator then
=? But, that doesn't match up with my observation.
So as three in the same questions..
- What does the equal operator (
- What does the
- What criteria does spatially equal include that
=does not include?