Re: multi-column btree index for real values

From: Oleg Bartunov <oleg(at)sai(dot)msu(dot)su>
To: Martin Weinberg <weinberg(at)osprey(dot)astro(dot)umass(dot)edu>
Cc: Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, Martijn van Oosterhout <kleptog(at)svana(dot)org>, "Martin D(dot) Weinberg" <weinberg(at)astro(dot)umass(dot)edu>, <pgsql-general(at)postgresql(dot)org>
Subject: Re: multi-column btree index for real values
Date: 2002-10-06 04:06:03
Message-ID: Pine.GSO.4.44.0210060805290.23264-100000@ra.sai.msu.su
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On Sat, 5 Oct 2002, Martin Weinberg wrote:

> Thanks Bruce. Some simple tests on a 10 million tuple data base shows
> that r-tree works well for this. (It took me a while to realize
> that I had to sort boxes of zero area rather than points).
>
> However, it seems that the rtree index has a serious memory leak for
> 7.2.2. Is that known?

probably, try contrib/rtree_gist

>
> --Martin
>
> Bruce Momjian wrote on Sat, 05 Oct 2002 14:30:47 EDT
> >Martin Weinberg wrote:
> >> Martijn,
> >>
> >> Thanks. So that implies that a multidimensional btree index is
> >> useless for two columns of floats (one will probably always
> >> be searching on the first index for a tree of large height).
> >>
> >> Let me restate my question as an example. Supose I have columns
> >> of longitude and latitude. What is the best indexing strategy to
> >> find all tuples with in a two dimensional bound of longitude and
> >> latitude. E.g. with where clause
> >>
> >> lat between 21.49 and 37.41 and
> >
> >Oh, rtree. That is exactly the index type you want.
> >
> >--
> > Bruce Momjian | http://candle.pha.pa.us
> > pgman(at)candle(dot)pha(dot)pa(dot)us | (610) 359-1001
> > + If your life is a hard drive, | 13 Roberts Road
> > + Christ can be your backup. | Newtown Square, Pennsylvania 19073
> >
> >---------------------------(end of broadcast)---------------------------
> >TIP 2: you can get off all lists at once with the unregister command
> > (send "unregister YourEmailAddressHere" to majordomo(at)postgresql(dot)org)
> >
>
> ---------------------------(end of broadcast)---------------------------
> TIP 4: Don't 'kill -9' the postmaster
>

Regards,
Oleg
_____________________________________________________________
Oleg Bartunov, sci.researcher, hostmaster of AstroNet,
Sternberg Astronomical Institute, Moscow University (Russia)
Internet: oleg(at)sai(dot)msu(dot)su, http://www.sai.msu.su/~megera/
phone: +007(095)939-16-83, +007(095)939-23-83

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Patrick Nelson 2002-10-06 05:45:00 Proper Join and check
Previous Message Nikolaus Dilger 2002-10-06 03:17:38 Re: [ADMIN] Fast Deletion For Large Tables