[Fix](Nereids) fix missing comment when creating table (#31869)

This commit is contained in:
zy-kkk
2024-03-06 20:46:32 +08:00
committed by yiguolei
parent 686cbffd8a
commit 5c1c73e5bb

View File

@ -2414,6 +2414,8 @@ public class LogicalPlanBuilder extends DorisParserBaseVisitor<Object> {
if (ctx.INTEGER_VALUE() != null) {
bucketNum = Integer.parseInt(ctx.INTEGER_VALUE().getText());
}
String comment = ctx.STRING_LITERAL() == null ? "" : LogicalPlanBuilderAssistant.escapeBackSlash(
ctx.STRING_LITERAL().getText().substring(1, ctx.STRING_LITERAL().getText().length() - 1));
DistributionDescriptor desc = null;
if (ctx.HASH() != null) {
desc = new DistributionDescriptor(true, ctx.autoBucket != null, bucketNum,
@ -2473,7 +2475,7 @@ public class LogicalPlanBuilder extends DorisParserBaseVisitor<Object> {
engineName,
keysType,
ctx.keys != null ? visitIdentifierList(ctx.keys) : ImmutableList.of(),
"",
comment,
isAutoPartition,
autoPartitionExpr.build(),
partitionType,
@ -2495,7 +2497,7 @@ public class LogicalPlanBuilder extends DorisParserBaseVisitor<Object> {
engineName,
keysType,
ctx.keys != null ? visitIdentifierList(ctx.keys) : ImmutableList.of(),
"",
comment,
isAutoPartition,
autoPartitionExpr.build(),
partitionType,