How to map oracle timestamp to appropriate java type in hibernate?

Posted by jschoen on Stack Overflow See other posts from Stack Overflow or by jschoen
Published on 2010-03-18T22:46:28Z Indexed on 2010/03/18 22:51 UTC
Read the original article Hit count: 182

Filed under:
|
|
|

I am new to hibernate and I am stumped. In my database I have tables that have a columns of TIMESTAMP(6). I am using Netbeans 6.5.1 and when I generate the hibernate.reveng.xml, hbm.xml files, and pojo files it sets the columns to be of type Serializable. This is not what I expected, nor what I want them to be.

I found this post on the hibernate forums saying to place: in the hibernate.reveng.xml file.

In Netbeans you are not able to generate the mappings from this file (it creates a new one every time) and it does not seem to have the ability to re-generate them from the file either (at least according to this it is slated to be available in version 7).

So I am trying to figure out what to do. I am more inclined to believe I am doing something wrong since I am new to this, and it seems like it would be a common problem for others.

  • So what am I doing wrong?
  • If I am not doing anything wrong, how do I work around this?

I am using Netbeans 6.5, Oracle 10G, and I believe Hibernate 3 (it came with my netbeans).

Edit: Meant to say I found this stackoverflow question, but it is really a different problem.

© Stack Overflow or respective owner

Related posts about hibernate

Related posts about netbeans6.5