rdblue commented on a change in pull request #3135:
URL: https://github.com/apache/iceberg/pull/3135#discussion_r712323642
##########
File path: data/src/test/java/org/apache/iceberg/data/DeleteReadTests.java
##########
@@ -125,6 +166,42 @@ public void testEqualityDeletes() throws IOException {
Assert.assertEquals("Table should contain expected rows", expected,
actual);
}
+ @Test
+ public void testEqualityDateDeletes() throws IOException {
+ initTable2();
+
+ Schema deleteRowSchema = table2.schema().select("*");
+ Record dataDelete = GenericRecord.create(deleteRowSchema);
+ List<Record> dataDeletes = Lists.newArrayList(
+ dataDelete.copy("dt", LocalDate.parse("2021-09-01"), "data", "a",
"id", 1),
+ dataDelete.copy("dt", LocalDate.parse("2021-09-02"), "data", "b",
"id", 2),
+ dataDelete.copy("dt", LocalDate.parse("2021-09-03"), "data", "c",
"id", 3)
+ );
+
+ DeleteFile eqDeletes = FileHelpers.writeDeleteFile(
+ table2, Files.localOutput(temp.newFile()), Row.of(0), dataDeletes,
deleteRowSchema);
Review comment:
I don't see how this delete file would be applied. The partition you're
writing it to is `Row.of(0)`, which ends up being `1970-01-01`. That should
prevent the delete file from being found when planning, so none of the deletes
would be applied.
--
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: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]