Re: [GENERAL] COPY TO '|gzip > /my/cool/file.gz'

2011-07-22 Thread Willy-Bas Loos
On Wed, Jul 20, 2011 at 8:53 PM, Vibhor Kumar wrote: > You can use STDOUT to pipe output to a shell command and STDIN to read input > from shell command. > Something like given below: > psql -c "COPY mytable to STDOUT"|gzip >/home/tgl/mytable.dump.gz > > cat filename|psql -c "COPY mytable from ST

Re: [GENERAL] COPY TO '|gzip > /my/cool/file.gz'

2011-07-20 Thread Craig Ringer
On 21/07/11 01:59, david.sahag...@emc.com wrote: > From May 31, 2006; 12:03pm . . . > > "It struck me that we are missing a feature that's fairly common in Unix > programs. > Perhaps COPY ought to have the ability to pipe its output to a shell command, > or read input from a shell command. " > Ma

Re: [GENERAL] COPY TO '|gzip > /my/cool/file.gz'

2011-07-20 Thread Vibhor Kumar
On Jul 20, 2011, at 11:29 PM, wrote: > From May 31, 2006; 12:03pm . . . > > "It struck me that we are missing a feature that's fairly common in Unix > programs. > Perhaps COPY ought to have the ability to pipe its output to a shell command, > or read input from a shell command. " > Maybe som