Backup database with entries > 8192 KBytes - Mailing list pgsql-hackers

From G. Anthony Reina
Subject Backup database with entries > 8192 KBytes
Date
Msg-id 37A737D0.C185EF38@nsi.edu
Whole thread Raw
Responses Re: [HACKERS] Backup database with entries > 8192 KBytes
List pgsql-hackers
I know that I can't insert a tuple into Postgres > 8192 KBytes long. We
need to store data in a variable length float array which can take up a
total length of greater than this amount. To get around the limit, we
simply insert a zeroed array (which takes up less character space) and
then update the array in chunks specifying where in the array to put the
data.


e.g. INSERT INTO tablename VALUES '{0,0,0,0,0,0, .... }';       to pad the array with zeros (this, of course, has to be
less
than 8192 KBytes)

then

UPDATE tablename SET array1[1:100] = '{123.9, 12345.987, 123454555.87,
.... }'
etc.

This works fine.

Okay, long intro for a short question. When we do a pg_dump and then
restore the database should the COPY contained within the pg_dumped file
be able to handle these long arrays?

-Tony Reina





pgsql-hackers by date:

Previous
From: Hannu Krosing
Date:
Subject: Re: [HACKERS] Mega-commits to "stable" version
Next
From: The Hermit Hacker
Date:
Subject: Re: [HACKERS] Mega-commits to "stable" version