On and off there's been discussions of getting COPY support into the JDBC
driver and I produced a patch to provide a stream based interface over a
year and a half ago . At the time we did not commit that because we
had grand plans to provide a friendly interface to users so they did not
have to know the internals of how COPY actually represents data. This
mostly happened off-list between Oliver and I, but the key suggestion is
available here . This allows you to use SQLOutput  calls like
writeTimestamp or writeArray to directly send Java objects to the database
without having to know the Postgresql specific text representation of
them. This turned out to be harder and more involved than it looked and I
just let the patch languish, always intending to return to it, but as time
has passed I've actually had less time to dedicate to the driver instead
I know a number of people are already/still using the original patch I
provided, but at the same time they have also (indirectly) indicated that
some additional support is needed .
So the question is what should we do?
1) Just get the raw stream interface into the official release and let the
end user deal with reading and writing the stream. That's all I'll use
and I don't care about anything else.
2) Don't give up, get the friendly SQLInput/SQLOutput interface in because
this is what I really want.
3) Put in the raw stream interface, but keep working to also add the
friendly one. I'll understand if the interface changes and I have to
modify my code a bit.
pgsql-jdbc by date
|Next:||From: Dave Cramer||Date: 2005-08-19 12:07:17|
|Subject: Re: COPY support survey|
|Previous:||From: Kris Jurka||Date: 2005-08-19 05:34:38|
|Subject: Re: Updated high-unicode patch|