Need help with Hibernate? Read this first:
http://www.hibernate.org/ForumMailingli ... AskForHelp
Hibernate version: 3.1
My question is related to SessionFactory's
Session openSession(Connection connection) method.
I have databases say DB1, DB2, DB3, ... DBn
These databases have same schema (these databases have same table structures ).
I am creating one SessionFactory and using
Session openSession(Connection connection) method to obtain the Session. The connection provided to the openSession method may be for DB1 or DB2 or DB3 or ... DBn.
I am able to fetch the records using above technique. I am doing only read operations and not any updates.
My question is, is this approach valid ? Or I have to create SessionFactory for each database.