• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Urgent Help required.. Inserting my Cutomized Java Class object in the database

 
liinaa
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I want to insert and retrieve a java class object into the database.Is this possible.Can setObject and getObject jdbc methods be used to achieve this and if so, what should be the corressponding datatype in the database.
If there's some other way, kindly pass on the information
Its urgent and any help would be appreciated
Thanks in advance!
 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"liinaa",
Javaranch has a Naming Policy to help promote a professional atmosphere.
You'll find that having a valid name also increases your chance of having your queries answered.
ta,
Dave.
 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm not aware of the set/getObject methods in JDBC, where are they?
You'll most likely store them as BLOBs in the database and have to read and write the objects as binary streams. You'll probably need to use the java.io.ObjectInputStream and ObjectOutputStream to move them around.
Can we get an idea on WHY you are storing classes in the database, sounds like a strange exercise...
Dave.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic