| Joined: Fri Oct 03, 2003 11:58 am
 Posts: 14
 | 
				
					| How do I configure Hibernate to access multiple databases?
 I am using hibernate.cfg.xml as the configuration file.
 
 Currently I have the following config:
 
 =========================================
 <hibernate-configuration>
 
 <session-factory>
 <!-- properties -->
 <property name="hibernate.connection.driver_class">org.postgresql.Driver</property>
 <property name="hibernate.connection.url">jdbc:postgresql://fuji.contego.net:5432/arx</property>
 <property name="hibernate.connection.username">nagios</property>
 <property name="hibernate.connection.password">nagios</property>
 <property name="hibernate.connection.pool_size">1</property>
 <property name="show_sql">true</property>
 <property name="hibernate.dialect">net.sf.hibernate.dialect.PostgreSQLDialect</property>
 
 <!-- mapping files -->
 <mapping resource="com/contego/arx/domain/Address.hbm.xml"/>
 <mapping resource="com/contego/arx/domain/Company.hbm.xml"/>
 <mapping resource="com/contego/arx/domain/Device.hbm.xml"/>
 <mapping resource="com/contego/arx/domain/Contact.hbm.xml"/>
 <mapping resource="com/contego/arx/domain/ContactGroup.hbm.xml"/>
 <mapping resource="com/contego/arx/domain/Configuration.hbm.xml"/>
 </session-factory>
 
 </hibernate-configuration>
 =========================================
 
 Thanks,
 
 Chris
 
 
 |  |