This is an automated email from the ASF dual-hosted git repository.
morrysnow pushed a commit to branch branch-2.1
in repository https://gitbox.apache.org/repos/asf/doris.git
The following commit(s) were added to refs/heads/branch-2.1 by this push:
new 29898d0dbc3 [fix](downgrade) partition key should write upper case
null type to image (#39776)
29898d0dbc3 is described below
commit 29898d0dbc3027e1cffe484fd1e4f24897af2fc5
Author: morrySnow <[email protected]>
AuthorDate: Thu Aug 22 18:42:08 2024 +0800
[fix](downgrade) partition key should write upper case null type to image
(#39776)
---
fe/fe-core/src/main/java/org/apache/doris/catalog/PartitionKey.java | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git
a/fe/fe-core/src/main/java/org/apache/doris/catalog/PartitionKey.java
b/fe/fe-core/src/main/java/org/apache/doris/catalog/PartitionKey.java
index 9f129235dfa..ac2beeadb85 100644
--- a/fe/fe-core/src/main/java/org/apache/doris/catalog/PartitionKey.java
+++ b/fe/fe-core/src/main/java/org/apache/doris/catalog/PartitionKey.java
@@ -376,7 +376,7 @@ public class PartitionKey implements
Comparable<PartitionKey>, Writable {
for (int i = 0; i < count; i++) {
PrimitiveType type = types.get(i);
if (keys.get(i).isNullLiteral()) {
- Text.writeString(out, Type.NULL.toString());
+ Text.writeString(out, PrimitiveType.NULL_TYPE.toString());
} else {
Text.writeString(out, type.toString());
}
@@ -396,11 +396,11 @@ public class PartitionKey implements
Comparable<PartitionKey>, Writable {
public void readFields(DataInput in) throws IOException {
int count = in.readInt();
for (int i = 0; i < count; i++) {
- PrimitiveType type =
PrimitiveType.valueOf(Text.readString(in).toUpperCase());
+ PrimitiveType type = PrimitiveType.valueOf(Text.readString(in));
boolean isMax = in.readBoolean();
if (type == PrimitiveType.NULL_TYPE) {
String realType = StringLiteral.read(in).getStringValue();
- type = PrimitiveType.valueOf(realType.toUpperCase());
+ type = PrimitiveType.valueOf(realType);
types.add(type);
keys.add(NullLiteral.create(Type.fromPrimitiveType(type)));
continue;
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]