Forums Register Login

Connecting Multiple database using Hibernate

+Pie Number of slices to send: Send
I am making insurance management system and i am using struts and hibernate capabilities but I am facing a problem with connecting multiple database using hibernate in myeclipse.Can anybody tell me how to connect multiple database using hibernate?Please


Thanks in advance!!
+Pie Number of slices to send: Send
Howdy Greenhorn!

You can set up multiple session factories and give them a different hibernate config file. So, you might have hibernate_ora.xml and hibernate_db2.xml.

Then, each session will give a connection to a different database.

If more complex associations are needed, there is a Hibernate project called Shards that is designed just for this purpose. You can fine out more about it at hibernate.org.

-Cameron McKenzie
Do not set lab on fire. Or this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com


reply
reply
This thread has been viewed 1536 times.
Similar Threads
Mule ESB - Hibernate
Applet
Multiple JDBC Connections via Hibernate
Hibernate in Netbeans 6.9.1
Should I use Hibernate?
More...

All times above are in ranch (not your local) time.
The current ranch time is
Apr 16, 2024 05:56:29.