geometric functions - Mailing list pgsql-general

From Piotr Stelmaszyk
Subject geometric functions
Date
Msg-id 2432.990526@fanthom.math.put.poznan.pl
Whole thread Raw
List 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@fanthom.math.put.poznan.pl ---------/
/----- mailto:kelman@alpha.net.pl -----------------------/
/--------------------------------------------------------/



pgsql-general by date:

Previous
From: "Ji Li"
Date:
Subject: DBI connection problem
Next
From: Mario Luis Peralta
Date:
Subject: (no subject)