-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: [lame] hbm2java, mysql, autogenerate and @GeneratedValue
PostPosted: Mon Jun 05, 2006 9:30 am 
Newbie

Joined: Mon Jun 05, 2006 9:22 am
Posts: 3
most of my mysql 5 tables have autogenerated id. however, I am not able to run hbm2java (v3.1.0 b5) to make the @GeneratedValue annotation *just* for needed ids. I can either have no @GeneratedValue or to have it on all ids, and both is not correct. ok, i can fix this manually and with hard-coded column names in getTableIdentifierStrategyName() but this is not the way to go.

So I just wonder: is it possible for hibernatetool to 'figure out' which columns are autogenerated and to produce valid annotation just where it is needed?

thanx in advance!


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jun 05, 2006 10:23 am 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 6:10 am
Posts: 8615
Location: Neuchatel, Switzerland (Danish)
hbm2java doesn't autodetect anything, it just dumps the hibernate meta model...maybe you are talking about the reverse engineering ?

here you can set it in reveng.xml per table.

we don't have autodetection of the id generator yet. patches welcome.

_________________
Max
Don't forget to rate


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.