Re: [PATCH] COPY .. COMPRESSED

Claudio Freire <klaussfreire@gmail.com>

From: Claudio Freire <klaussfreire@gmail.com>
To: Stephen Frost <sfrost@snowman.net>
Cc: Peter Eisentraut <peter_e@gmx.net>, Tom Lane <tgl@sss.pgh.pa.us>, Simon Riggs <simon@2ndquadrant.com>, PostgreSQL-Dev <pgsql-hackers@postgresql.org>
Date: 2013-01-15T17:22:56Z
Lists: pgsql-hackers
On Tue, Jan 15, 2013 at 1:08 PM, Stephen Frost <sfrost@snowman.net> wrote:
> Where it does work well is when you move into a bulk-data mode (ala
> COPY) and can compress relatively large amounts of data into a smaller
> number of full-size packets to be sent.

Well... exactly. COPY is one case, big result sets is another.
And packet headers can include whether each packet is compressed or
not, which is quite transparent and easy to handle. There could even
be a negotiation phase and make it backwards-compatible.