Parsing a text file into an array

From: Scott (sroth1979_at_hotmail.com)
Date: 08/16/04


Date: 16 Aug 2004 08:34:01 -0700

I am new to perl, and have not found any good examples of parsing to
help me out. I have a text file that I am reading into an array that
has to be parsed out and put into another file. I have not found any
good examples of this. Does anyone know of any?

For example the text file looks like this...
900002 "Test,Test" 1/1/2004 F 21

with tabs inbetween each of the colums of the text file.



Relevant Pages

  • Re: "Did not find leading dereferencer" - new findings to an old puzzle
    ... since I thought such an attempt on parsing would have to ... Perl, and T::B is entirely written in Perl. ... certain error go away, is very, very typical for buffer overrun. ... but you ignored that advice. ...
    (comp.lang.perl.misc)
  • Re: speed test
    ... How about the files parsing with huge size? ... I'm afraid perl can't finish the daily job so I want to know the speed ... It sounds a lot like you are parsing logs from a web server or well actually ... size of the data to parse grows there will be a bigger and bigger desire for ...
    (perl.beginners)
  • [perl-python] 20050121 file reading & writing
    ... # reading the one line ... # proper in large programs. ... # or in Python terminal, ... # in perl, similar functionality exists. ...
    (comp.lang.perl.misc)
  • [perl-python] 20050121 file reading & writing
    ... # reading the one line ... # proper in large programs. ... # or in Python terminal, ... # in perl, similar functionality exists. ...
    (comp.lang.python)
  • faster /etc/services
    ... access getservbyname() only once per program :-) ... Instead of reading and parsing /etc/services every time, ... socket and ask a daemon for the information. ...
    (freebsd-net)