Beefy Boxes and Bandwidth Generously Provided by pair Networks
There's more than one way to do things
 
PerlMonks  

Re: Reading huge file content

by johngg (Canon)
on Dec 06, 2007 at 14:17 UTC ( [id://655412]=note: print w/replies, xml ) Need Help??


in reply to Reading huge file content

my $data = ""; while (read (FH,$data, $buffer) ){ $data .= $data; }

I don't think that's going to work very well. Each time do the read in the while you just clobber what you have read before. Perhaps you should append $data to a different scalar. I would also cut down the size of your reads and possibly introduce an updating counter to see how far you have successfully read through the file.

Cheers,

JohnGG

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://655412]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others romping around the Monastery: (9)
As of 2024-03-28 10:17 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found