A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
OCA Java SE 8 Programmer I Study Guide
this week in the
Object Relational Mapping
Can we have 2 hibernate.cfg.xml?
Joined: May 08, 2006
Mar 03, 2011 00:22:38
Can we have 2 hibernate.cfg.xml files in class path? If yes, how hibernate will pickup the one? or will it pickup both the files?
Thanks in Advance...
Joined: Mar 22, 2005
Mar 03, 2011 00:44:02
What are you trying to achieve? What's wrong with using a single file?
Joined: Dec 06, 2010
Mar 03, 2011 01:23:28
yes you can have multiple config files (as with
in case of collision, the later mapping will override the first one...
I agree. Here's the link:
subject: Can we have 2 hibernate.cfg.xml?
hibernate.cfg.xml required in version 2.x?
Can we create a sessionFactory from a combination of Annotated Classes and Hbm files.
When to declare mapping resources in hibernate configuration files
are these 2 same or not
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015