A Techno Blog, mainly about Java

Combo Meal: Hibernate 3 with Derby

I have been getting familiar with the Derby  open source database  which was contributed by IBM (Cloudscape).

As a learning exercise, I decided to integrate the use of Derby in sampling Hibernate 3.

I have read parts of Pro Hibernate 3 and Hibernate Quickly. I liked both books, but I think the Manning book was more what I was looking for. I needed a book that covered the X-Doclet with Hibernate 3.

Hibernate3 needed from what i can tell these Jars: cglib-2.1.3, dom4j-1.6.1, ehcache-1.1, hibernate3, jta, asm

I start off using an ANT build file schema-export target to invoke the schema generator:

<target name="schema-export">
    <taskdef name="schemaexport"
         <classpath refid="runtime.classpath"/>

My hibernate property values to use Derby as the database looked like this (note: you can also specify these values in the hibernate config xml file):


Connecting to the derby database:

ij> connect ‘jdbc:derby:net://localhost:1527/test’ user ‘user1’ password ‘user1’;

ij> select tablename from sys.systables where tabletype = ‘T’;

I did not do the upgrade, but this was helpfull.


January 8, 2006 - Posted by | Hibernate & ORM

No comments yet.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: