geometric functions

From: Piotr Stelmaszyk <kelman(at)fanthom(dot)math(dot)put(dot)poznan(dot)pl>
To: PgSQL-general <pgsql-general(at)postgresql(dot)org>
Subject: geometric functions
Date: 1999-05-26 08:23:29
Message-ID: 2432.990526@fanthom.math.put.poznan.pl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hello,

I'm taking part in writing application that displays every part of
world map. I have in database classes containing:
point-objects - (postrgesql point type)
polygon-objects - (postrgesql polygon type)
path-objects - (postrgesql path type)

One of queries should do sth. like this:
select object from map
where objectiscontainedby(box);

My problem of course is how should this looong procedure look like.
There is no problem with points - postgres has proper function (and
even operator) that checks if point is inside box.
There _is_ problem with paths and polygons. I need all these objects
that:

-are completely inside box,
-are partly inside box (but have at least one point inside)
-are partly inside box (but _don't_ have any point inside)

any ideas how to solve this?
thanx.

/--------------------------------------------------------/
/- Piotr Stelmaszyk |---- Student of Computer Science ---/
/------------------ | at Poznan University of Technology /
/----- mailto:kelman(at)fanthom(dot)math(dot)put(dot)poznan(dot)pl ---------/
/----- mailto:kelman(at)alpha(dot)net(dot)pl -----------------------/
/--------------------------------------------------------/

Browse pgsql-general by date

  From Date Subject
Next Message Michal Samek 1999-05-26 08:47:43 So slow inserts... Why?
Previous Message jerome doucerain 1999-05-26 07:12:32 Re: [GENERAL] how to cancel a request in progress ?