[postgis-users] Chained Intersections?

Mark Cave-Ayland mark.cave-ayland at ilande.co.uk
Tue Oct 10 04:01:18 PDT 2006


On Mon, 2006-10-09 at 22:23 -0700, Curtis W. Ruck wrote:

> I wrote a pl/pgsql function that i thought would do this, far below
> labeled Intersection_All.  The problem with this is that it needs to
> be called from a FROM clause because it returns a SETOF records, but
> within a FROM clause i can't do an aggregate method collect(the_geom).
> (I also tried a subquery in the FROM clause).
> 
> Does anyone have any suggestions on how to warp Postgres/PostGIS into
> doing this?
> 
> Curtis W. Ruck
> <unnamed large entity>


Hi Curtis,

Can you provide examples of the queries you have tried (along with any
error messages that you get). Subqueries and aggregates in a FROM clause
work fine, for example:

	select * from (select count(*) FROM pg_class) AS foo;


Kind regards,

Mark.





More information about the postgis-users mailing list