Welcome, Guest. Please login or register.

Author Topic: Perl Help for a networking script.  (Read 2372 times)

harry

  • Full Member
  • ***
  • Posts: 124
    • View Profile
Perl Help for a networking script.
« on: October 11, 2012, 04:52:42 AM »
Hi ,
I am reading a CSV file in perl where date is 10-Oct-12 format, how to convert this date in perl script while reading to "dd/MM/YY format?

I hope some one can help me here.

Tahnks in advance.

lukas

  • Newbie
  • *
  • Posts: 7
    • View Profile
Re: Perl Help for a networking script.
« Reply #1 on: October 11, 2012, 08:03:28 AM »
use Date::Calc qw(:all);
use POSIX;
print strftime( '%d/%m/%y', localtime( Mktime( Decode_Date_EU2( '10-Oct-12', 1 ), 0, 0, 0 ) ) );

harry

  • Full Member
  • ***
  • Posts: 124
    • View Profile
Re: Perl Help for a networking script.
« Reply #2 on: October 12, 2012, 06:34:39 AM »
It worked,
Thanks a lot