[mapserver-users] Regular Expressions Question

Tim McGuire tim.mcguire at dnr.state.mn.us
Thu Jun 14 15:10:19 EDT 2001


/[^a]/ will match anything that is not an 'a'
so it will return a match for 'Bubba' because there are characters there that are not 'a'

you could do /[^b-zA-B0-9 ]/
and that would not match any string with an 'a'  (except if there were '@#$%' or something)


HTH

Tim McGuire

>>> Daniel Morissette <morissette at dmsolutions.ca> 06/14/01 09:27AM >>>
"Andries J. Algera" wrote:
> 
> I would try to do something like this: /[^a]/
> 

Thanks for all the replies... I tried using

  EXPRESSION  /[^a]/

but it doesn't work... it still matches fields that contain an 'a'.  The
'man regex' on my test system (RH6.2) does mention the [^...]
'non-matching list' operator so it should support it but it doesn't
work.

Has anyone ever been able to use the [^...] operator with MapServer
REGEX?  Perhaps it's just the way the above expression is built that's
not correct?

P.S. I also tried /[^a]*/ and /[^a]+/ just in case but it made no
difference.
-- 
------------------------------------------------------------
 Daniel Morissette               morissette at dmsolutions.ca 
 DM Solutions Group              http://www.dmsolutions.ca/ 
------------------------------------------------------------
  Don't put for tomorrow what you can do today, because if 
      you enjoy it today you can do it again tomorrow.




More information about the mapserver-users mailing list