-->
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: hbm2ddl doesn't update table
PostPosted: Thu Dec 27, 2007 11:25 am 
Newbie

Joined: Fri Aug 31, 2007 6:02 am
Posts: 2
Hibernate version: 3.2.5.GA

Name and version of the database you are using: MySQL 5 InnoDB


I've got in my config file:
<property name="hibernate.hbm2ddl.auto">update</property>

On first time the table is generated ok. But if I change the for example length or type of attribute (@Column(length=xx)) the hibernate doesn't make this change on table. If I add the new attribute there is the change in table so this case works ok.

Any idea how to make hibernate to automatically change column type in table?

Regards,
Maciej Matecki


Top
 Profile  
 
 Post subject: hbm2ddl doesn't update table
PostPosted: Sun Feb 03, 2008 6:44 pm 
Newbie

Joined: Sun Feb 03, 2008 6:40 pm
Posts: 1
I have the same problem, I've figured that any changes to existing columns are not taken into effect.

It looks like it only scans based on table and column names. If they exist, it doesn't inspect their properties.

Can anyone confirm this and state if this functionality is to be expected in the near future?

Thanks
Jonny


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.