Re: gzip/zcat changes file?
On Mon, Oct 22, 2001 at 04:55:56PM -0400, Brian Stults wrote:
> I am using a statistical package (Stata 7.0 for linux) that, among other
> things, can read in raw data and create a database from it. I have an
> ascii file of data, and the program reads the data just fine. The files
> that I work with are quite large, though, so it is useful to gzip them
> (in fact they come that way) and have the program call out to the shell
> and have it zcat the data to a named pipe and then read it from the
> pipe. When I do this, the program will read the data, but only the
> first observation.
Chances are that the program doesn't like reading from a pipe, perhaps
because it seeks back and forward in the input data.
> Can anyone think of something that gzip/zcat would be doing to the
> data to cause this behavior.
Have you tried just catting the file to a (named) pipe and seeing if
that exhibits the same behaviour? If so, it's almost certainly the
problem above.
Cheers,
--
Colin Watson [cjwatson@flatline.org.uk]
Reply to: