Don't ask to ask, just ask | |
PerlMonks |
PCRE help with negative matchby Oolankaloophid (Initiate) |
on Aug 11, 2013 at 00:21 UTC ( [id://1048960]=perlquestion: print w/replies, xml ) | Need Help?? |
Oolankaloophid has asked for the wisdom of the Perl Monks concerning the following question: Trying to write a regex to NOT match line 1 but will match line 2 and 3. The string will not be anchored. 9759-222-sdfgh1-001-aaa-1234-abc 8898-222-sdfgh1-001-aaa-1234-abc 1234-222-sdfgh1-001-aaa-1234-abc My regex is: (?<!9759-222)(\w\- {24})
Back to
Seekers of Perl Wisdom
|
|