This week's book giveaway is in the OCMJEA forum.
We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line!
See this thread for details.
The moose likes JDBC and the fly likes Storing HashMap or TreeMap in a BLOB Column Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Storing HashMap or TreeMap in a BLOB Column" Watch "Storing HashMap or TreeMap in a BLOB Column" New topic
Author

Storing HashMap or TreeMap in a BLOB Column

Surya Ram
Greenhorn

Joined: Aug 09, 2004
Posts: 7
Hi,
Could anybody give some codesnippets of inserting a HashMap or TreeMap into BLOB Oracle COLUMN.

Thanks for your help
Jeanne Boyarsky
internet detective
Marshal

Joined: May 26, 2003
Posts: 30392
    
150

Surya,
You can create a Blob by creating a BinaryStream or byte[] with your data. So you would loop through the datastructure and write it out to a stream.


[Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Blogging on Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, OCAJP, OCPJP beta, TOGAF part 1 and part 2
 
It is sorta covered in the JavaRanch Style Guide.
 
subject: Storing HashMap or TreeMap in a BLOB Column