Re: Workarounds for getBinaryStream returning ByteArrayInputStream on bytea

Radosław Smogura <rsmogura@softperience.eu>

From: Radosław Smogura <rsmogura@softperience.eu>
To: Александър Шопов <lists@kambanaria.org>
Cc: <pgsql-jdbc@postgresql.org>
Date: 2010-11-24T22:04:49Z
Lists: pgsql-hackers
I see only two possibilities
1. Decrease fetch size, e.g. to 1.
2. Refactor schema.

Kind regards,
Radek

On Wed, 24 Nov 2010 22:50:46 +0200, Александър Шопов
<lists@kambanaria.org>
wrote:
> Hi everyone,
> I have a table containing file contents in bytea columns.
> The functionality I am trying to achieve is having a result set
> containing such columns, iterating over them and streaming them while
> zipping them.
[...]
> So what am I options? Refactor the DB schema to use blobs rather than
> bytea? Is it impossible to have bytea read in chunks?
> Kind regards:
> al_shopov

-- 
----------
Radosław Smogura
http://www.softperience.eu