[Mapserver-users] querybyattributes logical expression

Ryan, Adam ARyan at co.linn.or.us
Wed May 26 14:24:18 EDT 2004


Using "([AREA] > 4000000)" works for me.  Silly question: Are you sure your
Area field is numeric?  

Adam 

-----Original Message-----
From: AARON KONING [mailto:aaronkoning at shaw.ca] 
Sent: Wednesday, May 26, 2004 10:54 AM
To: Mapserver-users at lists.gis.umn.edu
Cc: Eric Bridger
Subject: Re: [Mapserver-users] querybyattributes logical expression


Hi,

I have also used different operators in class expressions. I tried your
suggestion but it did not work. Strangely the single quotes are needed
regardless of the data type of the field. So that the following query does
work:

$queryString = "('[AREA]' = '10')"
$queryItem = 'AREA';
> >    $map->querybyattributes($queryitem,$queryString,MS_MULTIPLE);



----- Original Message -----
From: Eric Bridger <eric at gomoos.org>
Date: Wednesday, May 26, 2004 4:03 am
Subject: Re: [Mapserver-users] querybyattributes logical expression

> At 11:11 PM 05/25/2004 -0700, AARON KONING wrote:
> >Hi List,
> >
> >Just wondering if anyone has had success using querybyattributes with 
> >the '>', '<', '>=', '<=' operators? I have
> been using the 'NOT', 'AND', 'OR',
> >and '=' operators with success.
> >
> >The following statement fails:
> >
> >    $queryString = "('[AREA]' > '10')"
> >    $queryItem = 'AREA';
> >    $map->querybyattributes($queryitem,$queryString,MS_MULTIPLE);
> 
> I haven't used querybyattributes() but have use comparison
> operators in CLASS EXPRESSION's.
> I would try:
> "([AREA] > 10)"  i.e. these are number values not strings.
> 
> _______________________________________________
> Mapserver-users mailing list Mapserver-users at lists.gis.umn.edu
> http://lists.gis.umn.edu/mailman/listinfo/mapserver-users
> 

_______________________________________________
Mapserver-users mailing list
Mapserver-users at lists.gis.umn.edu
http://lists.gis.umn.edu/mailman/listinfo/mapserver-users



More information about the mapserver-users mailing list