Not an expert in perl (nor in english), but let's try ;-)
if your output file is not supposed to get too big,
consider 'writing' first your output lines in a hash
... $hash{1} = line 1; and so on
(later, writing line 10 for eg.)
if (whatever)
{
$hash{5} .= these few words;
}
when finished,
Why not just use Tie::File module ?
http://search.cpan.org/author/JHI/perl-5.8.0/lib/Tie/File.pm#SYNOPSIS
José.
-Original Message-
From: Hello Buddy [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, October 09, 2002 11:29 AM
To: [EMAIL PROTECTED]
Subject: I need help for handling text
Thanks Jean,
But I am afraid to say that my log file is
at least over 60 K lines. I do not know how to do it.
How can I insert any words in any place of open text
file?
Regards
Winn
--- Jean Padilla [EMAIL PROTECTED]
wrote:
Not an expert in perl (nor in english), but let's
try ;-)
if
Hi,
I've downloaded Tie::File module from
http://search.cpan.org/author/MJD/Tie-File-0.93/
and given it a little try : works fine.
(even for me : Just Another Perl Newbie).
Thanks, José.
NYIMI Jose (BMB) a écrit :
Why not just use Tie::File module ?
On Wed, Oct 09, 2002 at 02:28:58AM -0700, Hello Buddy wrote:
What I am facing now is when I write to format text file, suppose I was
currently in line 10 for my formatted text file and I want to append some
word in line 5 of formatted text file.
Please see perldoc -q line in a file, or