I’m trying to use MySQL and ebeans for saving my tasks. When i apply the script, i get this error :
[PersistenceException: ERROR executing DML bindLog[] error[Field 'id' doesn't have a default value]]
Before using MySQL as DB, it worked fine with H2 DB in memory as well as File system…
How can I resolve this error?
just got the same error.
add AUTO_INCREMENT to your id field and the constraint in your evolution script.Like this
now it works
EDIT:
if you annotate the field ‘id’ in the model with @Id evolutions should automatically add AUTO_INCREMENT and the constraint