regex question

Dan Shoop shoop at iwiring.net
Thu Apr 5 10:25:32 PDT 2007


At 11:31 AM -0400 4/5/07, János wrote:
>Hi,
>
>I need a pointer to a documentation that 
>describe well the extended regular expressions.
>
>I need to match some strings that must start 
>with any of 'S', 'A', 'C' or 'N', followed by 
>two digits followed by a '-' /dash/, followed by 
>one to six digits.
>
>So I created the following one:
>
>"^[ACNS][0-9]{2}-[0-9]+$"
>
>I am not so sure that it really fixes the dash 
>to the 4th position and it definitely would 
>allow more than 6 digits at the end.
>
>Any good advise ?

What's wrong with the O'Reilly book?

www.oreilly.com/catalog/regex2/
-- 

-dhan

------------------------------------------------------------------------
Dan Shoop                                                   AIM: iWiring
Systems & Networks Architect                      http://www.ustsvs.com/
shoop at iwiring.net                                http://www.iwiring.net/
1-714-363-1174

"The wise man doesn't give the right answers, he poses the right
questions." -- Claude Levi-Strauss

------------------------------------------------------------------------

iWiring provides systems and networks support for Mac OS X, unix, and
Open Source application technologies at affordable rates.


More information about the MacOSX-admin mailing list