split is probably the easiest way to go here.
--my @values = split /\|/, $var; if ($values[4] eq $var) { # Values matched. # Use value in $values[10] } else { # values didn't match. }
"Perl makes the fun jobs fun
and the boring jobs bearable" - me
In reply to Re: how to match and assign?
by davorg
in thread how to match and assign?
by slok
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |