csun5285 commented on code in PR #54406:
URL: https://github.com/apache/doris/pull/54406#discussion_r2261925143
##########
fe/fe-core/src/main/java/org/apache/doris/catalog/Column.java:
##########
@@ -946,6 +946,18 @@ public void checkSchemaChangeAllowed(Column other) throws
DdlException {
if (generatedColumnInfo != null || other.getGeneratedColumnInfo() !=
null) {
throw new DdlException("Not supporting alter table modify
generated columns.");
}
+
+ if (type.isVariantType() && other.type.isVariantType()) {
+ if (this.getVariantMaxSubcolumnsCount() !=
other.getVariantMaxSubcolumnsCount()) {
Review Comment:
有,test_predefine_ddl.groovy
##########
fe/fe-core/src/main/java/org/apache/doris/alter/SchemaChangeHandler.java:
##########
@@ -3401,4 +3433,20 @@ private void checkOrder(List<Column> targetIndexSchema,
List<String> orderedColN
nameSet.add(colName);
}
}
+
+ private void checkAddVariantColumnAllowed(OlapTable olapTable, Column
newColumn) throws DdlException {
Review Comment:
修过了,这种不允许建表和加列
--
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]