in reply to Re^3: no of lines in uploaded text file
in thread no of lines in uploaded text file

Hi JavaFan ,

After using seek function , I could reuse File handle.
I did not get anything from `wc -l `. I was expecting no of lines and name of file. This $FileHandle is a file handle only.
I got following error when i used wc -l
Tue May 11 11:45:17 2010 error client 192.168.1.101 sh: -c: line 0: `wc -l IO::File=GLOB(0xc7e51d0)', referer: http://1 Is the reason for this error is File handle. I was trying to read no of lines from file handle not file.
What could be the solution for this ?

Regards,
Prafull
  • Comment on Re^4: no of lines in uploaded text file

Replies are listed 'Best First'.
Re^5: no of lines in uploaded text file
by JavaFan (Canon) on May 13, 2010 at 12:51 UTC
    wc takes a file name as argument, not a stringified file handle reference.

    Hence, I believe you lied when you claimed your program worked from the command line.