ibatis-user-java mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Oscar Picasso <oscgoo...@yahoo.com>
Subject Re: Postgresql and blob
Date Sun, 28 Aug 2005 14:43:49 GMT
I can make it work for select but for insert I get:
...
 ERROR: column "content" is of type oid but expression is of type bytea
...

Looking at the BlobTypeHandlerCallback source I find something that I don't
understand.

getResult(ResultGetter getter) returns basically getter.getBlob.getBytes(...);

while setParameter(ParameterSetter setter, Object parameter) sets directly the
provided parameter. There is no mention here of a Blob object.

This code seems consistent with the results I get but obviously it's not the
results that one would expect for insertions. How can it works for other
databases? That is blob -> byte[] 'conversion' done by the TypeHandlerCallback
but no 'conversion' done by the TypeHandlerCallback for insertions.

--- Nathan Maves <Nathan.Maves@Sun.COM> wrote:

> As long as the driver supports it I believe that iBatis will.
> 
> Nathan
> 
> On Aug 27, 2005, at 4:12 PM, Oscar Picasso wrote:
> 
> > Hi,
> >
> > Does the lastest ibatis java release support blob for Postgresql?
> >
> > Or do we need to write a custome TypeHandlerCallback?
> >
> > Oscar
> >
> >
> >
> >
> >
> > __________________________________
> > Yahoo! Mail
> > Stay connected, organized, and protected. Take the tour:
> > http://tour.mail.yahoo.com/mailtour.html
> >
> >
> 
> 


__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 

Mime
View raw message