http://www.perlmonks.org?node_id=821125


in reply to Convert Date formats

If you want to stay with Date::Manip, you'll have to feed the parser with a valid date: 'NOV-07' is not a date, but a month (there is no day specified).

Taking care of that, the following code works:
#!/usr/bin/perl use strict; use warnings; use Date::Manip; my $thingy = 'NOV-2007'; my $date = UnixDate( ParseDate( "1-$thingy" ), '%Y/%m' ); print "$date\n";
Good luck,

Krambambuli
---