pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Peter Koczan <pjkoczan@gmail.com>
To: giuseppe.derossi@email.it
Cc: pgsql-admin@postgresql.org
Subject: Re: geometry poligons performance and index
Date: Tue, 4 Sep 2007 21:58:02 -0500
Message-ID: <4544e0330709041958o3bd58974gf39f64ae083c81d6@mail.gmail.com> (raw)
In-Reply-To: <77edfa82157a698e4c207fcdaccc52f2@164.129.1.43>
References: <77edfa82157a698e4c207fcdaccc52f2@164.129.1.43>

>  The results are ok, but the query is too slow. I tried to applay a GIST and
>  gtree index but performance did not improve.
>  By explaining the query I see that the where condition gets the query slow.
>  Is there a more simple way to check if two poligons have a not null
>  intersection (they overlap)?
>
>  Is there a kind of index I can use ?

If you stored the polygon geometries in the same table, you could use
a functional index (give the CREATE INDEX statement a function to
evaluate rather than a column). Check the CREATE INDEX page for
caveats. Beware that the index would grow with the square of the
number of rows if you did it like this.

Peter



view thread (4+ messages)

Message-ID: <4544e0330709041958o3bd58974gf39f64ae083c81d6@mail.gmail.com>
Permalink:  ../4544e0330709041958o3bd58974gf39f64ae083c81d6@mail.gmail.com/
Also on:    postgresql.org/message-id/4544e0330709041958o3bd58974gf39f64ae083c81d6@mail.gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-admin@postgresql.org
  Cc: pjkoczan@gmail.com, giuseppe.derossi@email.it
  Subject: Re: geometry poligons performance and index
  In-Reply-To: <4544e0330709041958o3bd58974gf39f64ae083c81d6@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox