csun5285 commented on code in PR #70408:
URL: https://github.com/apache/doris/pull/70408#discussion_r4674892554
##########
fe/fe-core/src/main/java/org/apache/doris/alter/SchemaChangeHandler.java:
##########
@@ -1008,6 +1009,13 @@ private boolean processModifyColumn(ModifyColumnOp
modifyColumnOp, OlapTable ola
if (col.getName().equalsIgnoreCase(newColName)) {
modColIndex = i;
found = true;
+ // A restated definition parses as V2 and cannot state
variant_enable_typed_paths_to_sparse, but the
+ // column keeps the layout its data is stored with.
+ if (col.getType().isVariantType() &&
modColumn.getType().isVariantType()) {
+ modColumn.setType(((VariantType) modColumn.getType())
+ .withSerializeType(col.getVariantSerializeType())
+
.withEnableTypedPathsToSparse(col.getVariantEnableTypedPathsToSparse()));
+ }
Review Comment:
ok
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]