Arnab Karmakar has uploaded this change for review. ( http://gerrit.cloudera.org:8080/25189
Change subject: IMPALA-15616: Treat DEFAULT NULL on nullable Iceberg columns as no default ...................................................................... IMPALA-15616: Treat DEFAULT NULL on nullable Iceberg columns as no default On Iceberg V3 tables, DEFAULT NULL or DEFAULT CAST(NULL AS <type>) was sent to catalogd as the text 'NULL' and parsed as a value of the column type. STRING columns silently got the 4-character string 'NULL' as their default, and other types failed in catalogd with a raw parse error. A NULL default on a nullable column now means no default, which matches Iceberg semantics. CREATE TABLE and ADD COLUMN(S) set neither initial-default nor write-default, and ALTER COLUMN SET DEFAULT NULL drops the write-default like DROP DEFAULT. Testing: - Added FE analysis tests and e2e tests in iceberg-v3-default-values.test for CREATE TABLE, ADD COLUMN(S) and ALTER COLUMN SET DEFAULT with NULL and CAST(NULL AS <type>), on STRING and non-STRING columns. Change-Id: I3d8909ca0004c1eb7fcf3cc1dc9952679ce70eda --- M fe/src/main/java/org/apache/impala/analysis/AlterTableAddColsStmt.java M fe/src/main/java/org/apache/impala/analysis/AlterTableAlterColStmt.java M fe/src/main/java/org/apache/impala/analysis/ColumnDef.java M fe/src/main/java/org/apache/impala/analysis/CreateTableStmt.java M fe/src/main/java/org/apache/impala/analysis/Expr.java M fe/src/test/java/org/apache/impala/analysis/AnalyzeDDLTest.java M testdata/workloads/functional-query/queries/QueryTest/iceberg-v3-default-values.test 7 files changed, 100 insertions(+), 11 deletions(-) git pull ssh://gerrit.cloudera.org:29418/Impala-ASF refs/changes/89/25189/1 -- To view, visit http://gerrit.cloudera.org:8080/25189 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: newchange Gerrit-Change-Id: I3d8909ca0004c1eb7fcf3cc1dc9952679ce70eda Gerrit-Change-Number: 25189 Gerrit-PatchSet: 1 Gerrit-Owner: Arnab Karmakar <[email protected]>
