How will you configure Hibernate?

Answer

To configure hibernate, you need hibernate.cfg.xml or hibernate.properties file and *.hbm.xml files, all these files are used by Configuration class to create sessionFactory, which in turn creates the session instances. Session instances are the primary interface for persistence services.

The hibernate.cfg.xml or hibernate.properties files are used to configure the hibernate service (database connection driver class, database connection URL, connection user name, connection password, dialect, mapping resources etc.).

The *hbm.xml files are used for mapping persistent objects to relational database.

From Java 5 onwards you can configure and map persistent objects through annotations.

All hibernate Questions

Ask your interview questions on hibernate

Write Your comment or Questions if you want the answers on hibernate from hibernate Experts
Name* :
Email Id* :
Mob no* :
Question
Or
Comment* :
 





Disclimer: PCDS.CO.IN not responsible for any content, information, data or any feature of website. If you are using this website then its your own responsibility to understand the content of the website

--------- Tutorials ---