Hibernate Introduction

Hibernate is Object Relational Solution (ORM) for Java. Hibernate was introduced in 2001 by Gavin King as an alternative for EJB2.

Why Hibernate

Before Hibernate introduced working with both Object-Oriented software and Relational Databases can be cumbersome and time consuming. Development costs are significantly higher due to a paradigm mismatch between how data is represented in objects versus relational databases.

Hibernate simplifies mapping from Java classes to database tables, and from Java data types to SQL data types. In addition, it provides data query and retrieval facilities. It can significantly reduce development time otherwise spent with manual data handling in SQL and JDBC.

Hibernate’s design goal is to relieve the developer from 95% of common data persistence-related programming tasks by eliminating the need for manual, hand-crafted data processing using SQL and JDBC

The process of mapping Java Entity Object to Relational Database column called Object Relational Mapping (ORM). We will see about ORM in details in next post.

Advantage of Hibernate

  1. Light weight and open source under LGPL license.
  2. Hibernate take care mapping java object to database tables, saves manual coding works.
  3. Hibernate provides apis for storing and retrieving java object to and from database
  4. Changing from one database to another database easy, just we need to change configuration in XML or property file.
  5. Hibernate support all major RDBMS databases.

Posts You may Like

  1. How to Convert Object to JSON String using GSON
  2. Java 8 Overview and New Features
  3. How to Convert JSON String to Object using GSON
  4. How to retrieve all the files from Directory using Java File.listFiles()
  5. How to search a word inside String
  6. How to search file from directory using Java
  7. How to Read file using FileInputStream
  8. Remove the particular character from string
  9. Restful Webservice HelloWorld Jersey 2.x Example
  10. How to add value to all types of Collections
  11. How to make read-only file in Java
  12. How to traverse the directories using Java
  13. JSON Streaming API to Read JSON
  14. How to find the size of directory using FileUtils
  15. Jackson Streaming API to Write JSON

Be the first to comment

Leave a Reply

Your email address will not be published.