[Mapserver-users] Optimising PostGIS relates/subselects/views
Antti.Roppola@brs.gov.au
Antti.Roppola@brs.gov.au
Tue, 4 Feb 2003 11:08:25 +1100
Hello all,
If I have my attribute data and PostGIS geometries in the
same table, my map draws in around 4 seconds. Viz:
DATA "the_geom from mylayer"
CLASSITEM "value"
If I use attributes from other tables, my map draws in 82 seconds. Viz:
DATA "the_geom FROM
(SELECT mylayer.oid AS oid,
mylayer.the_geom AS the_geom,
mytable.value AS value
FROM mylayer, mytable
WHERE mylayer.lut=mytable.lut)
AS mylayer
USING oid
USING srid=-1"
CLASSITEM "value"
Obviously something index related, but is it the question is what?
My table has around 2600 shapes in it, and pulling in the atrribute
data using psql is fast, so I think it's indexing of the subselect
rather than the relate that's the issue.
TIA,
Antti
_______________________________________________
Mapserver-users mailing list
Mapserver-users@lists.gis.umn.edu
http://lists.gis.umn.edu/mailman/listinfo/mapserver-users