GeeCON Prague 2014*
The moose likes Object Relational Mapping and the fly likes Dynamic connection using Hibernate Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "Dynamic connection using Hibernate" Watch "Dynamic connection using Hibernate" New topic
Author

Dynamic connection using Hibernate

Levi Mendes
Greenhorn

Joined: Oct 11, 2011
Posts: 4
Hello everybody,

Can anyone post some example showing dinamically how to connect the SQLServer with a java app using Hibernate?

Today, I'm using the simple hibernate.cfg.xml, in it I put the connection credentials hardcoded. Now the app need to connect the database according to the user credentials,
In other words I can't put the credentials fixed in this file.
How can I achieve it?


Thank so much.
 
GeeCON Prague 2014
 
subject: Dynamic connection using Hibernate