Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer
 
PerlMonks  

Re^2: Regex Extraction Help

by Flexx (Pilgrim)
on Aug 09, 2012 at 17:26 UTC ( #986559=note: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    $record = 'A;B;C;D';
    
  2. or download this
    $second_field = (split ';', $record)[1];
    
  3. or download this
    A;B
    #foo;B;ar
    ;B
    
  4. or download this
    if($record =~ m/^.;(.);.;.$/) {
      $second_field = $1;
    }
    

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (5)
As of 2014-08-30 16:35 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The best computer themed movie is:











    Results (293 votes), past polls