Re: Avoiding Duplicate Entries

2002-07-12 Thread drieux
On Wednesday, July 10, 2002, at 09:12 , John W. Krahn wrote: [..] > > Something like that. :-) But what if the log file has been rotated and > the last line is no longer in the file? > > my $last_line = get_last_line_from_cache(); > > open LOG, or die "$!"; > > while ( ) { > rollback_

Re: Avoiding Duplicate Entries

2002-07-10 Thread John W. Krahn
Drieux wrote: > > On Tuesday, July 9, 2002, at 06:25 , John W. Krahn wrote: > [..] > > One way would be to cache the last line read and the next time you read > > the file loop until that line is encountered and only process the lines > > after it. > > john, > > when you say 'cache the last lin

Re: Avoiding Duplicate Entries

2002-07-10 Thread drieux
On Tuesday, July 9, 2002, at 06:25 , John W. Krahn wrote: [..] > One way would be to cache the last line read and the next time you read > the file loop until that line is encountered and only process the lines > after it. john, when you say 'cache the last line' - are you meaning #

Re: Avoiding Duplicate Entries

2002-07-09 Thread John W. Krahn
Joshua Scott wrote: > > I'm very new to Perl programming so please bear with me. I'm working on a > program that will open up a certain logfile, read the contents, upload > certain content to a database and update the status to the same database. > > The goal is to run this program once a week.

Avoiding Duplicate Entries

2002-07-09 Thread Scott, Joshua
I'm very new to Perl programming so please bear with me. I'm working on a program that will open up a certain logfile, read the contents, upload certain content to a database and update the status to the same database. The goal is to run this program once a week. Currently the program just uplo