You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@iceberg.apache.org by "zhongyujiang (via GitHub)" <gi...@apache.org> on 2023/03/17 16:02:35 UTC

[GitHub] [iceberg] zhongyujiang commented on a diff in pull request #7132: Core, Spark: Fix delete with filter on nested columns

zhongyujiang commented on code in PR #7132:
URL: https://github.com/apache/iceberg/pull/7132#discussion_r1140422212


##########
spark/v3.3/spark-extensions/src/test/java/org/apache/iceberg/spark/extensions/TestDelete.java:
##########
@@ -510,6 +510,22 @@ public void testDeleteWithConditionOnNestedColumn() {
         "Should have expected rows", ImmutableList.of(), sql("SELECT id FROM %s", tableName));
   }
 
+  @Test
+  public void testDeleteWithFilterOnNestedColumn() {
+    createAndInitNestedColumnsTable();
+
+    sql("INSERT INTO TABLE %s VALUES (1, named_struct(\"c1\", 3, \"c2\", \"v1\"))", tableName);
+    sql("INSERT INTO TABLE %s VALUES (2, named_struct(\"c1\", 2, \"c2\", \"v2\"))", tableName);
+
+    sql("DELETE FROM %s WHERE complex.c1 = 3", tableName);

Review Comment:
   Delete conditions in `testDeleteWithConditionOnNestedColumn` can not be push down, so added this UT.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@iceberg.apache.org
For additional commands, e-mail: issues-help@iceberg.apache.org