Order problem in GiST index

From: Kotroczó Roland <kotroczo(dot)roland(at)inf(dot)elte(dot)hu>
To: "pgsql-hackers(at)lists(dot)postgresql(dot)org" <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Order problem in GiST index
Date: 2023-05-01 21:13:54
Message-ID: DB4PR10MB69669979A286F619D74ECB62B16E9@DB4PR10MB6966.EURPRD10.PROD.OUTLOOK.COM
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hi!
We are developing a GiST index structure. We use M-tree for this work. We have a problem with it. We would like to get some closest neighbors. In my select we order the query by distance, and we use limit. Sometimes it works well, but in some cases I don’t get back the closest points. If we set the recheck flag to true, the query results will be correct.
I examined the CUBE extension and realized the recheck flag is false. According to the comments, it’s not necessary to set the recheck to true in CUBE. What conditions must be met to work well even with recheck=false? How is it working in CUBE?
Thanks for your replies.

Browse pgsql-hackers by date

  From Date Subject
Next Message Regina Obe 2023-05-01 21:50:49 RE: [PATCH] Support % wildcard in extension upgrade filenames
Previous Message Eric Ridge 2023-05-01 21:05:08 Re: [PATCH] Support % wildcard in extension upgrade filenames