Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Mutiple DBs and one Session Factory???

 
Thillai Sakthi
Ranch Hand
Posts: 109
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All:
I am new to hibernate. Need a quick help please.........
I wish to show a report joining two tables - these tables are in different databases. As multiple DBs are used, I have created two .cfg.xml files and loaded them manually for Configuration and SessionFactories....
With two different SessionFactories, dont know how do I query and get data???

Any help would be highly appreciated.
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hibernate cannot map related tables where the tables are in two different DBs. You need to look at your DB docs about cross database relationships.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic