I have been working on various projects in which I used hibernate in many projects. However, when in an interview, I was asked about why one should choose hibernate, I thought I should put together the benefits and the reasons to choose Hibernate.
What hibernate is basically ?
Hibernate is an O/R mapping which stands for Object/Relational mapping. This means that hibernate relates/maps objects with the database tables (also known as relations).
The developer no more need to write all the SQL manually using the JDBC API. It also helps the developer to concentrate on the business logic of the project instead of giving time to manual SQL queries and the consequent bugs in it. This helps increase the project productivity.
It generates the necessary SQL queries on the backend, making it easy for the developer to maintain the code.
Hibernate is portable. Regardless, of the database, you can write your code and run it with every database just by making a few change in the hibernate configuration file.
Hibernate provides all the above mentioned O/R mapping features.
Hibernate is open source and companies who tend to work using open source projects can benefit a lot from it.
Hibernate is a popular O/R mapping and there is a lot of support for bugs. It has been used in many projects, so there is a 99% chance that if you come across an error or problem using it, you can find it solution on the internet as there are many discussion boards and websites writing about it.
Hibernate is totally object oriented and it is easy to configure and learn.
Many popular IDEs (Netbeans, Eclipse..) provide support for code generation. If you have created you database, you can generate hibernate objects for all the tables with the click of a button.
Hibernate code generation
http://www.hibernate.org/255.html
http://www.hibernate.org/hib_docs/tools/reference/en/html_single/
http://wiki.netbeans.org/ReverseEngineering
7 Comments
Hello admin.
I am very pleased to see such a nice article.
You are very good at what you do.
Keep posting more nice articles.
Thanks again.
Thank you very much Tehmeena.
In sha Allah I’ll be posting more articles.
Thanks for the feedback. Stay tuned!
I’m not quite sure how to say this; you made it exmterely easy for me!
Very nice article. Clears everything.
Thank you Usmanayyy
Free info like this is an apple from the tree of knoeledgw.
Thank you Usman!