diqiu50 opened a new pull request, #13979: URL: https://github.com/apache/gravitino/pull/13979
### What changes were proposed in this pull request? Keep the existing default value when rebuilding the column in `updateColumnTypeFieldDefinition` for MySQL, OceanBase and StarRocks, consistent with Doris. Add a test for each. ### Why are the changes needed? `MODIFY COLUMN` replaces the whole column definition, so rebuilding it with `DEFAULT_VALUE_NOT_SET` silently drops the default value. Fix: #13978 ### Does this PR introduce _any_ user-facing change? Changing a column type now keeps its default value. If the old default is not valid for the new type, the database now rejects the change instead of silently dropping the default. ### How was this patch tested? Added `testAlterTableUpdateColumnTypeKeepsDefaultValue` to the MySQL, OceanBase and StarRocks table operations tests (Docker). All three pass locally. The MySQL test fails without the fix. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
