reading output file data as input data

From: Stephen Moon (vibfft_at_yahoo.com)
Date: 02/28/04


Date: 28 Feb 2004 14:51:08 -0800

At the command prompt,

I type "perl test.pl <file1> <file2> <file3>" to run the program.

Initially, I open <file1> as an input file and output the information
to <file2>. Later on in the same program, I use <file2> as an input
and write the output to <file3>.

I get an error saying that "filehandler FH opened for output only"
although I close the <file2> and reopen it with a new filehandle.

-Steve



Relevant Pages

  • Re: Query regarding set([])?
    ... and the order doesn't matter. ... in file1, check if line is present in file2. ... duplicates are impossible in the input file, ...
    (comp.lang.python)
  • Re: Query regarding set([])?
    ... I am looking for a script that compares file1 and file2, ... order doesn't matter ... duplicates are impossible in the input file, ...
    (comp.lang.python)
  • Re: simple ln question
    ... that makes it so the contents of file1 are the same as of file2, and if you change the contents of 1, the other ... prints the inode number for the file foobar. ...
    (Fedora)
  • RE: data conundrum
    ... in your spens you'll want to keep field names consistent. ... the specs will be the most tedious, but once theyr're done once they're done. ... in other words, you have file1, file2, file3..... ...
    (microsoft.public.access.externaldata)
  • RE: data conundrum
    ... let's say file1 looks like this: ... and let's say file2 looks like this: ... then you will probably have to create import specs for all 100 ... create from the .csv files) as opposed to using a form, ...
    (microsoft.public.access.externaldata)