You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Unfortunately there isn't anything we can do about that. It's a limitation of mysql/mariadb. If you are setting a comment and have more column settings besides the data type, you'll have to use or .
I created #3045 to add a warning, but that is all we are able to do.
Environment
Liquibase Version: 4.7.1
Liquibase Integration & Version: cli
Database Vendor & Version: Mysql 8.0
Operating System Type & Version: Windows 11
Description
setColumnRemarks used to update a comment on the database translate to a query that remove default value and not null flag from the target field:
ALTER TABLE database.table MODIFY COLUMN column_name VARCHAR(100) COMMENT 'comment';
If the field "column_name" has a default value or a not null flag, it will lose both after the comment update.
Steps To Reproduce
Update any database field with the following changeset, update type, columnName and tableName in the changeset:
Actual Behavior
setColumnRemarks remove not null flag and default value from the target column definition
Expected/Desired Behavior
setColumnRemarks should update the comment of a column without losing any other column definition.
The text was updated successfully, but these errors were encountered: