Query by point

DjwStone D.Stone at ED.AC.UK
Fri Jun 16 12:26:30 EDT 2006


I think I've sorted this problem (for the second time!).

The first thing I noticed was the DATA statement was wrongly bracketed, so
now it would read:

    DATA          "geom from (select dr, geom, stdname, reftostconf,
saintid, locationref, placename, deddlo, deddhi, dedicationtype, stdesc, oid
from saintloc where ((deddlo between 14010101 and 15001231) OR (deddhi
between 14010101 and 15001231)) AND dedicationtype = 'Church dedication') as
foo using srid=27700"

But I still found the original problem recurred, i.e. the layer would
display the correct points when the saint-name filter was supplied. However,
when query mode was invoked and one of the points was clicked, the result
template displayed data for a different church dedication at the same
location (when there were multiple possibilities). In effect, it seems the
filter was not being applied in query mode.

The solution (not fully tested) seems to be to add the saint-name criterion
to the DATA statement:

    DATA          "geom from (select dr, geom, stdname, reftostconf,
saintid, locationref, placename, deddlo, deddhi, dedicationtype, stdesc, oid
from saintloc where ((deddlo between 14010101 and 15001231) OR (deddhi
between 14010101 and 15001231)) AND dedicationtype = 'Church dedication' AND
stdname='%stname%') as foo using srid=27700"

and remove the FILTERITEM and FILTER lines.

Cheers,

Dave
--
View this message in context: http://www.nabble.com/Query-by-point-t1774168.html#a4903656
Sent from the Mapserver - User forum at Nabble.com.



More information about the mapserver-users mailing list