[
http://opensource.atlassian.com/projects/hibernate/browse/HHH-6935?page=c...
]
Torsten Krah commented on HHH-6935:
-----------------------------------
Workaround is to use a custom dialect which does map the boolean type to a bit(1) type
which does result in the "old" behaviour:
public class MyDialect extends MySQL5InnoDBDialect {
public MyDialect() {
super();
registerColumnType(Types.BOOLEAN, "bit(1)");
}
}
Now validate passes and all is like before, i'll hope, correct me if not, at least it
works for me.
HibernateException in mysql Found: bit, expected: boolean
---------------------------------------------------------
Key: HHH-6935
URL:
http://opensource.atlassian.com/projects/hibernate/browse/HHH-6935
Project: Hibernate Core
Issue Type: Bug
Components: core
Affects Versions: 4.0.0.Final
Environment: spring jpa hibernate project above mysql 5.1
Reporter: orasio spieler
Labels: BooleanType, mysql
Attachments: hib4-check.zip
Found the problem i also got org.hibernate.HibernateException: Wrong column type ...
Found: bit, expected: boolean
on BooleanType in hibernate 4 they changed the Ctor to
public BooleanType() {
this( org.hibernate.type.descriptor.sql.BooleanTypeDescriptor.INSTANCE,
BooleanTypeDescriptor.INSTANCE );
}
instead of old versions
public BooleanType() {
this( BitTypeDescriptor.INSTANCE, BooleanTypeDescriptor.INSTANCE );
}
spieler.orasio(a)gmail.com
--
This message is automatically generated by JIRA.
For more information on JIRA, see:
http://www.atlassian.com/software/jira