fix syntax error for CreateTableLikeStmt with partition properties (#34187)
fix syntax error for CreateTableLikeStmt with partition properties
This commit is contained in:
@ -28,6 +28,7 @@ import org.apache.doris.analysis.SlotRef;
|
||||
import org.apache.doris.common.AnalysisException;
|
||||
import org.apache.doris.common.DdlException;
|
||||
import org.apache.doris.common.util.ListUtil;
|
||||
import org.apache.doris.common.util.PropertyAnalyzer;
|
||||
|
||||
import com.google.common.base.Preconditions;
|
||||
import com.google.common.collect.Lists;
|
||||
@ -249,7 +250,7 @@ public class ListPartitionInfo extends PartitionInfo {
|
||||
|
||||
Optional.ofNullable(this.idToStoragePolicy.get(entry.getKey())).ifPresent(p -> {
|
||||
if (!p.equals("")) {
|
||||
sb.append("PROPERTIES (\"STORAGE POLICY\" = \"");
|
||||
sb.append(" (\"" + PropertyAnalyzer.PROPERTIES_STORAGE_POLICY + "\" = \"");
|
||||
sb.append(p).append("\")");
|
||||
}
|
||||
});
|
||||
|
||||
@ -25,6 +25,7 @@ import org.apache.doris.analysis.RangePartitionDesc;
|
||||
import org.apache.doris.analysis.SinglePartitionDesc;
|
||||
import org.apache.doris.common.AnalysisException;
|
||||
import org.apache.doris.common.DdlException;
|
||||
import org.apache.doris.common.util.PropertyAnalyzer;
|
||||
import org.apache.doris.common.util.RangeUtils;
|
||||
|
||||
import com.google.common.base.Preconditions;
|
||||
@ -299,7 +300,7 @@ public class RangePartitionInfo extends PartitionInfo {
|
||||
|
||||
Optional.ofNullable(this.idToStoragePolicy.get(entry.getKey())).ifPresent(p -> {
|
||||
if (!p.equals("")) {
|
||||
sb.append("PROPERTIES (\"STORAGE POLICY\" = \"");
|
||||
sb.append(" (\"" + PropertyAnalyzer.PROPERTIES_STORAGE_POLICY + "\" = \"");
|
||||
sb.append(p).append("\")");
|
||||
}
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user