problem with opening up huge sized file

Rick J pisium at yahoo.com
Mon Jan 22 14:01:19 CST 2001


Hi, Michael,

Your code and your error don't match.  Does test.pl
look more like this?
(The numbers to the left are line numbers.)

1:  #!/usr/bin/perl
2:
3:  open (F, "file_path") or die("Can't open the
file\n$!")
4:  while (<F>){
5:      do something;
6:  }

Sorry that I just skipped some new lines. Yes, the
error occurs at line3. As matter of fact, the same
error appears even without while loop, which means the
script only contains open sub.

Because of that, I guess at least perl's trying to
open up the file with open sub, and set the filehandle
position at first line? That's why at first I thought
perl tried to read in all the contents of that giant
file.

 
Thanks,

Rick

__________________________________________________
Do You Yahoo!?
Yahoo! Auctions - Buy the things you want at great prices. 
http://auctions.yahoo.com/
=================================================
Mailing list info:  If at any time you wish to (un|re)subscribe to
the list send the request to majordomo at hfb.pm.org.  All requests
should be in the body, and look like such
                  subscribe anchorage-pm-list
                  unsubscribe anchorage-pm-list



More information about the Anchorage-pm mailing list