[fix](schema) fix show create table get wrong random distribution info (#18895)

* [fix](schema) fix show create table get wrong random distribution info


---------

Signed-off-by: nextdreamblue <zxw520blue1@163.com>
This commit is contained in:
xueweizhang
2023-04-24 23:33:42 +08:00
committed by GitHub
parent 54d58364c1
commit efebb3d21e
3 changed files with 23 additions and 2 deletions

View File

@ -56,9 +56,9 @@ public class RandomDistributionInfo extends DistributionInfo {
public String toSql() {
StringBuilder builder = new StringBuilder();
if (autoBucket) {
builder.append("DISTRIBUTED BY RANDOM() BUCKETS AUTO");
builder.append("DISTRIBUTED BY RANDOM BUCKETS AUTO");
} else {
builder.append("DISTRIBUTED BY RANDOM() BUCKETS ").append(bucketNum);
builder.append("DISTRIBUTED BY RANDOM BUCKETS ").append(bucketNum);
}
return builder.toString();
}