Re: [Perl-unix-users] How to parse a date string and convert it into mm/dd/yyyy format

2007-01-05 Thread AITHA, BHEEMSEN \(SBCSI\)
Thanks, it worked. -Original Message- From: $Bill Luebkert [mailto:[EMAIL PROTECTED] Sent: Friday, January 05, 2007 11:32 AM To: AITHA, BHEEMSEN (SBCSI) Cc: perl-unix-users@listserv.ActiveState.com Subject: Re: [Perl-unix-users] How to parse a date string and convert it into mm/dd/

Re: [Perl-unix-users] How to parse a date string and convert it into mm/dd/yyyy format

2007-01-05 Thread $Bill Luebkert
AITHA, BHEEMSEN (SBCSI) wrote: > Hi, > > I have a file with the following as the first line. > > 760434|c|061230 > > I need to parse this line and read 061230 into a variable and then try > to convert that string into the date in format mm/dd/. Report any > error while converting the string.

Re: [Perl-unix-users] How to parse a date string and convert it into mm/dd/yyyy format

2007-01-05 Thread Andy_Bach
while (<>) { if ( not /\|/ ) { warn "bad data line: $_"; next; } # if no pipe chomp; my ($whoknows, $oneletter, $date_str ) = split(/\|/); if ( not defined( $date_str ) ) { warn "bad data line - no date string: $_"; next; } # if no date if ( len

[Perl-unix-users] How to parse a date string and convert it into mm/dd/yyyy format

2007-01-05 Thread AITHA, BHEEMSEN \(SBCSI\)
Hi, I have a file with the following as the first line. 760434|c|061230 I need to parse this line and read 061230 into a variable and then try to convert that string into the date in format mm/dd/. Report any error while converting the string. Any sample code would be a great help. I do no