Re: bytea vs. pg_dump - Mailing list pgsql-hackers

From Hannu Krosing
Subject Re: bytea vs. pg_dump
Date
Msg-id 1243633400.5399.31.camel@huvostro
Whole thread Raw
In response to Re: bytea vs. pg_dump  (Peter Eisentraut <peter_e@gmx.net>)
List pgsql-hackers
On Fri, 2009-05-29 at 11:06 +0300, Peter Eisentraut wrote:
> On Friday 29 May 2009 04:26:35 Bruce Momjian wrote:
> > Added to TODO:
> >     |Improve bytea COPY format
> >
> >     * http://archives.postgresql.org/pgsql-hackers/2009-05/msg00192.php
> 
> Btw., I have started to write some code for that.

why not copy bytea always in base64 encoded or similar format - this
will both save at least 2x the space on average random bytea data _and_
is probably faster, as it can be more easily done by table lookups in
bigger chunks

an alternative is to just escape minimal amount of characters, probably
just \0 , \n and \\

-- 
Hannu Krosing   http://www.2ndQuadrant.com
PostgreSQL Scalability and Availability   Services, Consulting and Training



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Testing of parallel restore with current snapshot
Next
From: Greg Stark
Date:
Subject: Re: search_path vs extensions