Composite keys with large columns as identifier or index and so with mysql with charset UTF8 you can have a such error using hdbm2ddl :
org.hibernate.tool.hbm2ddl.SchemaExport : Index column size too large. The maximum column size is 767 bytes.
To solve the problem we need to extends MySQL5InnoDBDialect and override getTableTypeString like that : @Override public String getTableTypeString() { return " ENGINE=InnoDB ROW_FORMAT=COMPRESSED"; }
Providing a such Dialect would be helpfull, but maybe providing a property where to provide mysql specific table type could be more customizable.
|