Hello
I’ve got an error when trying to add an NotNullConstraint on a MySQL table column.
Here are the versions :
Liquibase : 4.20.0
MySQL : 8+
And here are the following swripts I use
<update tableName="situation">
<column name="status_date" valueDate="CURRENT_TIMESTAMP"/>
<where>status_date IS NULL</where>
</update>
and
<addNotNullConstraint
columnName="status_date"
tableName="situation"
columnDataType="TIMESTAMP"
constraintName="not_null_status_date"/>
If the first one works perfectly, the second one throw me an error :
Caused by: java.sql.SQLSyntaxErrorException: Invalid default value for ‘status_date’
and it raises this enven if i add the attribute “defaultNullValue”
DOes someone has already encountered this problem and know how to solve it ?
Thank you