Hi buddy,
The procedure to use Hibernate within your application requires the following steps:
1. Create a Hibernate configuration object
2. Use the Hibernate configuration object to create a Hibernate factory object
3. Use the Hibernate factory object to create a Hibernate session object
4. Use the Hibernate session object to start a transaction (optional)
5. Employ the Hibernate session object to create, read, update, and delete data on the database
6. Commit the transaction (optional)
7. Close the session
For more Detail, Go thru the article by
George Franciscus and Danilo Gurovich.
Hope usefull.