Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl-Sensitive Sunglasses
 
PerlMonks  

Re: Regex, query

by kennethk (Abbot)
on Jan 24, 2013 at 16:03 UTC ( #1015192=note: print w/ replies, xml ) Need Help??


in reply to Regex, query

Assuming your input string is 'Michael please look at E123456', your regular expression expects a trailing space that is not there. Rather than looking for trailing white space, perhaps you'd like the non-whitespace character class \S (m/$mystring2\s*(\S*)/i)? See Using character classes.


#11929 First ask yourself `How would I do this without a computer?' Then have the computer do it the same way.


Comment on Re: Regex, query
Select or Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1015192]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (18)
As of 2015-07-01 20:14 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (19 votes), past polls