Mike Harding <mvh(at)ix(dot)netcom(dot)com> writes:
> I then get errors like
> ERROR: MemoryContextAlloc: invalid request size 2353010684
> ERROR: MemoryContextAlloc: invalid request size 1885489220
> and the third and fourth time I tried it it worked!
This is sounding like a corrupted-data issue. I'd suggest seeing
if you can dump and reload the table. Very likely you will find
that there are some corrupted rows :-(
regards, tom lane