Gergely Fürnstáhl has posted comments on this change. ( http://gerrit.cloudera.org:8080/19145 )
Change subject: IMPALA-11339: Add Iceberg LOAD DATA INPATH statement ...................................................................... Patch Set 3: (5 comments) The design generally looks good, added a few improvement possibilities http://gerrit.cloudera.org:8080/#/c/19145/3/fe/src/main/java/org/apache/impala/analysis/LoadDataStmt.java File fe/src/main/java/org/apache/impala/analysis/LoadDataStmt.java: http://gerrit.cloudera.org:8080/#/c/19145/3/fe/src/main/java/org/apache/impala/analysis/LoadDataStmt.java@225 PS3, Line 225: able staetement typo: table statement http://gerrit.cloudera.org:8080/#/c/19145/3/fe/src/main/java/org/apache/impala/analysis/LoadDataStmt.java@233 PS3, Line 233: StringBuilder createTmpTblQueryBuilder = new StringBuilder(); Building the queries manually with string appends is a bit hard to follow/maintain/extend. I think the Java way is to use a builder class. If we don't want to pull in a dependency, we could at least delegate the logic to a small compact class to support something like this: QueryBuilder.CreateTableLike(...).InputFileFormat(...).InPath(...).FileFormat(...).Location(...) http://gerrit.cloudera.org:8080/#/c/19145/3/fe/src/main/java/org/apache/impala/analysis/LoadDataStmt.java@240 PS3, Line 240: throw new AnalysisException("Only directories can be loaded into Iceberg " : + "tables."); IMPALA-11339 proposes a solution for single files as well, are we planning to cut that out of the scope and create a following JIRA? http://gerrit.cloudera.org:8080/#/c/19145/3/fe/src/main/java/org/apache/impala/analysis/LoadDataStmt.java@289 PS3, Line 289: deped ont he typo: depend on the http://gerrit.cloudera.org:8080/#/c/19145/3/fe/src/main/java/org/apache/impala/analysis/LoadDataStmt.java@301 PS3, Line 301: "Could not infer file format." This error message could be misleading in case of a valid but not orc nor parquet file. -- To view, visit http://gerrit.cloudera.org:8080/19145 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: Impala-ASF Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I8499945fa57ea0499f65b455976141dcd6d789eb Gerrit-Change-Number: 19145 Gerrit-PatchSet: 3 Gerrit-Owner: Tamas Mate <[email protected]> Gerrit-Reviewer: Gergely Fürnstáhl <[email protected]> Gerrit-Reviewer: Impala Public Jenkins <[email protected]> Gerrit-Reviewer: Zoltan Borok-Nagy <[email protected]> Gerrit-Comment-Date: Wed, 02 Nov 2022 10:00:55 +0000 Gerrit-HasComments: Yes
