<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=us-ascii">
<META content="MSHTML 6.00.2900.2722" name=GENERATOR></HEAD>
<BODY>
<DIV><FONT face="Trebuchet MS" size=2><SPAN class=453585716-12082005>I thought 
this might be a problem that others have confronted.</SPAN></FONT></DIV>
<DIV><FONT face="Trebuchet MS" size=2><SPAN 
class=453585716-12082005></SPAN></FONT> </DIV>
<DIV><FONT face="Trebuchet MS" size=2><SPAN class=453585716-12082005>When using 
queryByAttributes() (at least the PHP MapScript variety) there is an 
implicit queryByRect() with the map extent that happens before the 
attribute query.  So if the map is zoomed to an extent that doesn't contain 
the feature that you're looking for, you'll never find it.</SPAN></FONT></DIV>
<DIV><FONT face="Trebuchet MS" size=2><SPAN 
class=453585716-12082005></SPAN></FONT> </DIV>
<DIV><FONT face="Trebuchet MS" size=2><SPAN class=453585716-12082005>The way 
I've dealt with this is to set the extent of the map to the extent of the query 
layer (or some max extent) before doing the queryByAttributes().  This, 
however, also fails if the query layer has a maxscale that is less (in mapserver 
terms) than the map scale when zoomed to this new extent.  Getting around 
this requires temporarily setting the layer's maxscale to 
-1.</SPAN></FONT></DIV>
<DIV><FONT face="Trebuchet MS" size=2><SPAN 
class=453585716-12082005></SPAN></FONT> </DIV>
<DIV><FONT face="Trebuchet MS" size=2><SPAN class=453585716-12082005>Is this too 
obvious to be documented somewhere?  Or is there a better 
method?</SPAN></FONT></DIV>
<DIV><FONT face="Trebuchet MS" size=2></FONT> </DIV>
<DIV align=left><FONT face="Trebuchet MS" size=2>Tim Schaub</FONT></DIV>
<DIV align=left><FONT face="Trebuchet MS" size=2>406-579-5929</FONT></DIV>
<DIV align=left><FONT face="Trebuchet MS" size=2><A 
href="http://www.commenspace.org">CommEn Space</A></FONT></DIV>
<DIV> </DIV></BODY></HTML>