That seems to do the trick, but you might also want to check out some of the Date and Time modules for more advanced datetime munging.my $dt = "2003 % 05 % 1720:55:23"; my $date = sprintf "%d-%02d-%02d", $dt =~ /(\d+) % (\d+) % (\d{2})/; print "date - $date\n"; __output__ date - 2003-05-17
_________
broquaint
In reply to Re: Regex to parse a date
by broquaint
in thread Regex to parse a date
by MD
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |