aspose file tools*
The moose likes Object Relational Mapping and the fly likes Hibernate Tools: Reverse engineering behavior . . . Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Databases » Object Relational Mapping
Bookmark "Hibernate Tools: Reverse engineering behavior . . ." Watch "Hibernate Tools: Reverse engineering behavior . . ." New topic
Author

Hibernate Tools: Reverse engineering behavior . . .

Dallas Gimpel
Greenhorn

Joined: Apr 05, 2006
Posts: 2
After years of JDBC, I've finally been given a chance to take the Hibernate plunge. We have a legacy database that resides on an AS/400 for which I'm generating entity and dao code using the Hibernate Tools plug-in for Eclipse. The following is a snippet of a Subscriber.reveng.xml file I've built:


NOTE: In the xml above, <ttable> is intentionally spelled with two Ts to prevent it from being interpreted as html. In the actual reveng.xml file, it's spelled correctly.

Among others, I used the reverse engineering feature of Hibernate Tools as part of my pro-Hibernate argument. But to my disappointment, the customizations I've added to my Subscriber.reveng.xml file seem to have no effect whatsoever on the source code produced via Hibernate Tools & Eclipse. The class specified in ttable is ignored so that the entity classes produced are Customerdb, CustomerdbHome, and CustomerdbId (with every single field in the table defined as part of a composite key). The customizations I've added for the columns -> properties and the primary key definition are also completely ignored. I realize that I can refactor the names, etc., but according to Java Persistence with Hibernate this should work.

What am I missing???

thanks in advance,
dgg
Dallas Gimpel
Greenhorn

Joined: Apr 05, 2006
Posts: 2
Happened to come across this today . . . I had also posted my question to the Hibernate forum where it was eventually answered (thanks again, Max) so I thought I'd post a link to the resolution in case anyone else has a similar problem.
dgg
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Hibernate Tools: Reverse engineering behavior . . .
 
Similar Threads
Reverse enginerring not creating object into POJO
I'm not able to insert record in Derby using Hibernate
HibernateTools Generating Wrong Code
Need help with Reverse Engineering to create JAVA objects
Help with mapping set - Hibernate