[Geomoose-users] Query Service- Regex in Mapserver 6.0.1

Lucas Middleton lmiddleton at title-check.com
Thu Dec 8 11:42:46 EST 2011


I have been having trouble getting the query function to work. I have 
configured geomoose to jive with my data per the documentation, however 
I am receiving a parsing error from MapServer when I execute my query.

yyparse(): Expression parser error. syntax error
msEvalExpression: Expression parser error. Failed to parse expression: 
("[NAME]" =~ /.*kalamazoo.*/)

I believe that this is due to changes in MapServer expression parsing. I 
found this in the migration guide on MapServer's website:


      Mapfile Changes - Expression Parsing

  * a regex is now deliniated as a string (e.g. '^a' rather than /^a/)
  * the regex operator is ~ for case sensitive comparisons and ~* for
    case insensitive
  * case insensitive string comparison operator is =*

So this leads me to believe that MapServer is looking for an expression 
more like:

'[NAME]' =* '.*kalamazoo.*'

or perhaps

'[NAME]' ~* '.*kalamazoo.*'


I was hoping for some advice as to whether or not
a). I am on the right track and
b). Suggestions on modifying the query.php code to reflect regex 
changes. It seems to me that it would no longer be necessary to break 
down the search string into a|b the way that the "icase" comparators do 
currently...


Any advice would be greatly appreciated!

Thank you,

Luke






-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/geomoose-users/attachments/20111208/d2476696/attachment.html


More information about the Geomoose-users mailing list