Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:
open (DATABASE, "$filename" || &ErrorMessage); @entry = <DATABASE>; #Assign DB entrie +s to array close(DATABASE); @CurrentData = split(/\|/, $entry[$lines - 1]); #Assign last line + of data to array @PreviousData = split(/\|/, $entry[$lines - 1]); $count = $lines - 1; #Find previous we +eks data by comparing dates while (($PreviousData[1] eq $CurrentData[1]) && ($count >= 0)) { $count -= 1; @PreviousData = split(/\|/, $entry[$count]); }
Thanks for your time.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: comparing dates
by andreychek (Parson) on Oct 17, 2001 at 03:59 UTC | |
by blakem (Monsignor) on Oct 17, 2001 at 04:10 UTC | |
|
Re: comparing dates
by MrNobo1024 (Hermit) on Oct 17, 2001 at 08:02 UTC |