Re: point_ops for GiST
Emre Hasegeli <emre@hasegeli.com>
From: Emre Hasegeli <emre@hasegeli.com>
To: Alvaro Herrera <alvherre@2ndquadrant.com>
Cc: Robert Haas <robertmhaas@gmail.com>, Teodor Sigaev <teodor@sigaev.ru>,
Pgsql Hackers <pgsql-hackers@postgresql.org>
Date: 2015-06-13T21:04:00Z
Lists: pgsql-hackers
> Emre Hasegeli just pointed out to me that this patch introduced > box_contain_pt() and in doing so used straight C comparison (<= etc) > instead of FPlt() and friends. I would think that that's a bug and > needs to be changed -- but certainly not backpatched, because gist > indexes would/might become corrupt. The problem with this is BRIN inclusion opclass uses some operators to implement others. It was using box @> point operator to implement point ~= point operator by indexing points in boxes. The former doesn't use the macros, but later does. The opclass could return wrong result when the point right near the index boundaries. Currently, there are not BRIN opclasses for geometric types except box because of this reason. I would like to work on supporting them for the next release. I think the best way is to change the operators which are not using the macros to be consistent with the others. Here is the list: * polygon << polygon * polygon &< polygon * polygon &> polygon * polygon >> polygon * polygon <<| polygon * polygon &<| polygon * polygon |&> polygon * polygon |>> polygon * box @> point * point <@ box * lseg <@ box * circle @> point * point <@ circle I can send a patch, if it is acceptable.
Commits
Same data as JSON:
GET /api/v1/messages/:b64id/commits
the thread's linked commits as JSON, with link sources.
API reference →
-
Fix gist_box_same and gist_point_consistent to handle fuzziness correctly.
- 3c29b196b0ce 9.3.0 cited
-
Add point_ops opclass for GiST.
- 4cbe47393877 9.0.0 cited