Hibernate provides an Eclipse to common Hibernate tasks such as Creating / Updating a Database Schema, running Hibernate queries and creating simple Hibernate Mapping documents
Note this plugin will only work with Eclipse 2 (WSAD 5) and above. Queries and Schema features are Hibernate2 only
* Installation
- Unzip hibernator-0.9.x.zip into /plugins
- If you downloaded hibernator-0.9.x-nolibs.zip then you will need to add the following .jars that come with Hibernate
- xml-apis.jar
- commons-beanutils.jar
- commons-collections.jar
- commons-lang.jar
- commons-logging.jar
- dom4j.jar
- hibernate2.jar
- odmg.jar
- cglib.jar
- Restart Eclipse
* Connecting to a Database
- Open Hibernate Perspective
- Right click in connection view and select "Add"
- Select one or more projects from the list (All *.hbm.xml documents in the selected projects are Configured into Hibernate)
- Click next and enter the Database details (I will change this so you can select a hibernate.properties file instead)
- Click finish
- Click on the Hibernate Log View
- Select and right click on the new connection. Click on "Connect!"
- Confirm the mappings and connection are ok in the Log View
- Simply hit "Connect!" on any other connections to prepare them for Query or Schema Update/Create
* Running a query
- Make sure you have created and connected to a database as above
- Type your query into the "Query View" and hit "Execute"
- Not the table of results in the "Results View" or any errors in the "Log View"
* Updating / Creating Schema
- Make sure you have created and connected to a database as above
- Click on Create or Update Schema in the "Query View"
- Note the results in the "Log View"
* Creating a simple mapping document
- Go to menu Window->Show View->Other and select Hibernator
- Open up some Java source and the plugin will either display the mapping file .hbm.xml or a generated version
- To save the contents of the mapping file right click in the window and select "Save"
Download the latest (0.9) from - http://sourceforge.net/projects/hibernator
Report any bugs / Submit patches to - http://sourceforge.net/projects/hibernator
Original code from
- Christopher (Jozsa Kristof) dyn@on... (that's all the Sourceforge lists will show me)
Contributions from