Subject | Re: [Firebird-Java] Re: Problem when using Firebird + Hibernate + Blob fields |
---|---|
Author | Roman Rokytskyy |
Post date | 2005-09-09T19:22Z |
> Well..... it's being printed with c:out... is this the problem? :SI suspect that test case is necessary, unless some simple but invisible
> If not, I'll send you the test case
mistake has crippled your code. Please note, that BLOB is mapped into a
Types.BINARY type, which, according to the specification, has mapping to
byte[] data type. That means that ResultSet.getObject() for a BLOB column
will return you byte[], not Blob and not String. The BLOB SUB_TYPE 1 is
mapped into Types.LONGVARCHAR, which is mapped to String by default. And
BLOB SUB_TYPE < 0 (i.e. custom BLOB subtype) is mapped to Types.BLOB, which
is mapped in turn to java.sql.Blob.
If, however, you get that value from Hibernate directly, then I need a test
case to find the problem.
Roman