Hibernate Introduction

  • Facebook
  • Google
  • LinkedIn
  • Twitter

Hibernate is an open source ORM (object/relational mapping) tool for Java which simplifies the data creation, data manipulation and data access. It is a programming technique that maps the object to the data stored in the database Hibernate lets you develop persistent classes following common Java feature including association, inheritance, polymorphism, composition and the Java collections framework.

Hibernate is not only takes care of the mapping from Java classes to database tables (and from Java data types to SQL data types), but also provides data query and retrieval facilities and can significantly reduce development time. The ORM tool internally uses the JDBC API to interact with the database.

Below are the some main features of hibernate.

  • Sophisticated caching
  • Lazy loading
  • Eager loading
  • A lot less code to write
  • No SQL to write
  • ORM framework generates database-specific SQL.
  • Outer join fetching
  • Batch fetching
  • Support for optimistic locking with versioning
  • First level cache
  • Second-level cache
  • Query cache
  • Object-oriented query language
  • Criteria queries
  • Native SQL queries
  • Automatic Dirty Checking