How about this?
my $maxdate = "2006-06-06"; my( $m_year, $m_month ) = split /-/, $maxdate;
Sometimes it's about using the right tool for the task. split comes in handy.
Dave
In reply to Re: Regular expression
by davido
in thread Regular expression
by Rexcel
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |