| Author |
Few questions related to Hibernate.properties file
|
Aditya Kanitkar
Ranch Hand
Joined: Aug 08, 2009
Posts: 72
|
|
Hi,
I want to configure my hibernate settings with the help of Hibernate.properties file.
I've already written the contents in the file as well as the HBM file is also ready.
Contents from Hibernate.properties
My questions are...
1) Do i have to write hibernate.cfg.xml??
2) If yes, what should be written in it??
3) How can i map the .properties file , So that connection can be made...??
Please Help...
Thanks...
Aditya Kanitkar
|
 |
Aditya Kanitkar
Ranch Hand
Joined: Aug 08, 2009
Posts: 72
|
|
|
Has anybody, have any idea about this....???
|
 |
Victor Ramen
Ranch Hand
Joined: Jul 14, 2008
Posts: 56
|
|
Hello,
1) Do i have to write hibernate.cfg.xml?? - This is basically the same as hibernate.properties in xml format. If both files are present in classpath, xml will take precedence. If you want to take advantage of xml syntax, you can use this one.
2) If yes, what should be written in it?? Basically the same stuff as in hibernate.properties
3) How can i map the .properties file , So that connection can be made...?? When you create a SessionFactory and open a session, a connection will be made using the parameters provided in .properties files.
Hope this helps,
Roy
|
 |
 |
|
|
subject: Few questions related to Hibernate.properties file
|
|
|