aspose file tools*
The moose likes JDBC and the fly likes Retrieve byte Array stored in Oracle BLOB Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Retrieve byte Array stored in Oracle BLOB" Watch "Retrieve byte Array stored in Oracle BLOB" New topic
Author

Retrieve byte Array stored in Oracle BLOB

Kem Broder
Greenhorn

Joined: Jul 25, 2002
Posts: 6
Hi,
I've migrated from mySQL to Oracle and am having a problem reading a byte array that I have stored as a BLOB in Oracle. With mySQL the byte array was returned as I wanted, but with Oracle something strange is happening.
I'm using iBATIS to access the database. From some googling I've done I think that the byte array I am getting from Oracle is a representation of the BLOB rather than the data that I have stored in it. Any ideas how I can get my byte array back?
Any help greatly appreciated,
Cheers,
Kem
stu derby
Ranch Hand

Joined: Dec 15, 2005
Posts: 333
Have you seen Oracle's BLOB & CLOB example? It's here:
http://www.oracle.com/technology/sample_code/tech/java/sqlj_jdbc/files/advanced/advanced.html

It's the "LOB Datatype" example. The "source" and "readme" are incomplete but uselful, the other link downloads the source for a complete working Swing application.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Retrieve byte Array stored in Oracle BLOB