[mapserver-users] Query by attributes with PHP/MapScript
Armin Burger
Armin Burger <armin.burger@libero.it>
Thu, 3 Oct 2002 10:33:00 +0200
After some trials I found out that MapScript supports multicolumn
attribute queries via the 'setfilter()' method. The following worked
fine
$query = "(([AREA]>500000 AND [AREA]<=1000000) AND ([CODE]=311
OR [CODE]=312))";
$layer->setFilter($query);
$layer->queryByAttributes(MS_MULTIPLE);
Its's even possible to include regular expressions in the query string.
Armin