toadi has asked for the wisdom of the Perl Monks concerning the following question:
Ok I know this is crappy code, but I want to illustrate my logic problem.&write($firstline); foreach $do ( keys %doing) { DO DB query for $do where fo $do can be serveral bodylines; &write($bodyline); } &write($lastline); sub write { my $line = shift; open(FILE,">>$basepath/$filename") or die; print FILE $line . "\n"; close FILE; }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Logic problem
by trantor (Chaplain) on Nov 26, 2001 at 16:10 UTC | |
|
Re: Logic problem
by busunsl (Vicar) on Nov 26, 2001 at 16:14 UTC | |
|
Re: Logic problem
by guha (Priest) on Nov 26, 2001 at 15:55 UTC | |
|
Re: Logic problem
by hotshot (Prior) on Nov 26, 2001 at 15:52 UTC |