I am running with the below issue while taking pg_dump(PG14) of a table with bytea column.
pg_dump: error: Error message from server: ERROR: invalid memory alloc request size 1460154641 The command was: COPY TO stdout;
The table "ABC" in concern is just 60MB large(total size) and it has a bytea column.
But the error says is not able to allocate a request size of 1.3GB. What are we missing here? Could you please help? Thanks.
Update: I was able to take backup of the table using below command without error.
COPY public.abc TO stdout WITH (FORMAT binary); --Successful execution
But below command fails:
COPY public.abc TO stdout ; ERROR: invalid memory alloc request size 1480703501
Even the select query return same error :
select * from ABC ERROR: invalid memory alloc request size 1480703501
How did it even allow bytea column to be inserted with more than 1GB. Tha table is just 60Mb large and with just 1 row.