Re: flat file db (do I need mysql?)

2002-11-10 Thread Jenda Krynicky
From: Patricia Hinman <[EMAIL PROTECTED]> > I just wrote a script that reads yahoo directories, > and writes to a temp txt file the portion of > direcetories it's currently working with. Then copies > that temp file to a completed log file, and grabs the > next subcatagory to wo

Re: Flat File Db

2002-07-18 Thread drieux
On Wednesday, July 17, 2002, at 07:04 , George Schlossnagle wrote: >>> The main problem appears to be that instead of taking a different branch >>> if open() or flock() fails you continue on as if they had succeeded. > > flock($fh,LOCK_EX ) is a blocking call, so it won't return until the lock

Re: Flat File Db

2002-07-18 Thread Jenda Krynicky
From: George Schlossnagle <[EMAIL PROTECTED]> > >> The main problem appears to be that instead of taking a different > >> branch if open() or flock() fails you continue on as if they had > >> succeeded. > > flock($fh,LOCK_EX ) is a blocking call, so it won't return until the > l

Re: Flat File Db

2002-07-17 Thread George Schlossnagle
>> The main problem appears to be that instead of taking a different >> branch >> if open() or flock() fails you continue on as if they had succeeded. flock($fh,LOCK_EX ) is a blocking call, so it won't return until the lock is available. // George Schlossnagle // Principal Consultant // Omni

Re: Flat File Db

2002-07-17 Thread John W. Krahn
"John W. Krahn" wrote: > > Jeff wrote: > > > > From: John W. Krahn [mailto:[EMAIL PROTECTED]] > > > > > > Jeff wrote: > > > > > > > > I'm use flat files to manage a list containing approx 25,000 records. For > > > > updates, I write to a temp file then unlink main and rename temp file to > > > >

Re: Flat File Db

2002-07-17 Thread John W. Krahn
Jeff wrote: > > From: John W. Krahn [mailto:[EMAIL PROTECTED]] > > > > Jeff wrote: > > > > > > I'm use flat files to manage a list containing approx 25,000 records. For > > > updates, I write to a temp file then unlink main and rename temp file to > > > main. I use flock for both temp and main

Re: Flat File Db

2002-07-17 Thread George Schlossnagle
_); > next unless $name eq $update; > $new_location = "palm_bay"; > $_ = join( "|", $name, $team, $new_location); > } > continue { > print OUT $_ or print "Error writing $tmp_db: $!\n"; > } > close IN; > close OUT; >

RE: Flat File Db

2002-07-17 Thread Jeff
t;; } -----Original Message- From: John W. Krahn [mailto:[EMAIL PROTECTED]] Sent: Wednesday, July 17, 2002 8:11 PM To: [EMAIL PROTECTED] Subject: Re: Flat File Db Jeff wrote: > > I'm use flat files to manage a list containing approx 25,000 records. For > updates, I write to a temp

Re: Flat File Db

2002-07-17 Thread John W. Krahn
Jeff wrote: > > I'm use flat files to manage a list containing approx 25,000 records. For > updates, I write to a temp file then unlink main and rename temp file to > main. I use flock for both temp and main files during update. My main file > gets blown away on occasions. What gives? I can'