Re: KNN-GiST with recheck

Поиск
Список
Период
Сортировка
От Bruce Momjian
Тема Re: KNN-GiST with recheck
Дата
Msg-id 20140926011800.GA8130@momjian.us
обсуждение исходный текст
Ответ на Re: KNN-GiST with recheck  (Alexander Korotkov <aekorotkov@gmail.com>)
Ответы Re: KNN-GiST with recheck  (Alexander Korotkov <aekorotkov@gmail.com>)
Список pgsql-hackers
On Sun, Sep 14, 2014 at 11:34:26PM +0400, Alexander Korotkov wrote:
>     > Cost estimation of GiST is a big problem anyway. It doesn't care (and
>     > can't) about amount of recheck for regular operators. In this patch, same
>     > would be for knn recheck. The problem is that touching heap from access

This is very important work.  While our existing KNN-GiST index code
works fine for scalar values and point-to-point distance ordering, it
doesn't work well for 2-dimensional objects because they are only
indexed by their bounding boxes (a rectangle around the object).  The
indexed bounding box can't produce accurate distances to other objects. 

As an example, see this PostGIS blog post showing how to use LIMIT in a
CTE to filter results and then compute the closest object (search for
"LIMIT 50"):
http://shisaa.jp/postset/postgis-postgresqls-spatial-partner-part-3.html

This patch fixes our code for distances from a point to indexed 2-D
objects.

Does this also fix the identical PostGIS problem or is there something
PostGIS needs to do?

--  Bruce Momjian  <bruce@momjian.us>        http://momjian.us EnterpriseDB
http://enterprisedb.com
 + Everyone has their own god. +



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: better atomics - v0.6
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: Add CREATE support to event triggers