phpmapscript - query caching?
Chris Matheson
chris at CENTRALFRONTENAC.COM
Wed Jan 11 08:07:15 PST 2006
Hi Folks,
I'm using postGIS (v1.04), postgreSQL (v7.4.8) and phpmapscript (from
mapserver 4.4).
I need a bit of help. I think I am using the wrong approach to this
problem...
I'm creating a map with a report attached using php. I'm creating a
dynamic layer using postGIS & mapscript using a function like
$layer->set("data", $statement). Later I run the same statement using
pg_query($connection, $statement) to get the attributes.
Everything works, but, because the query is big, and I'm running it
twice, my script is really slow. It's got to be a bad way to do it, it
feels wrong, even to me. Is there a way to avoid running the query
against the db twice?
P.S. - I've tried using the attributes from the mapscript layer object,
but I didn't have much luck and fell back to running it with pg_query.
I want to run some php against the data to sort, filter and format it.
Chris M.
More information about the MapServer-users
mailing list