szehon-ho commented on code in PR #10203:
URL: https://github.com/apache/iceberg/pull/10203#discussion_r1643654326


##########
core/src/main/java/org/apache/iceberg/BaseEntriesTable.java:
##########
@@ -192,37 +188,46 @@ public <T> Boolean notNaN(BoundReference<T> ref) {
 
       @Override
       public <T> Boolean lt(BoundReference<T> ref, Literal<T> lit) {
-        return compareDateFileContent(ref, lit, compareResult -> compareResult 
< 0);
+        return ROWS_MIGHT_MATCH;
       }
 
       @Override
       public <T> Boolean ltEq(BoundReference<T> ref, Literal<T> lit) {
-        return compareDateFileContent(ref, lit, compareResult -> compareResult 
<= 0);
+        return ROWS_MIGHT_MATCH;
       }
 
       @Override
       public <T> Boolean gt(BoundReference<T> ref, Literal<T> lit) {
-        return compareDateFileContent(ref, lit, compareResult -> compareResult 
> 0);
+        return ROWS_MIGHT_MATCH;
       }
 
       @Override
       public <T> Boolean gtEq(BoundReference<T> ref, Literal<T> lit) {
-        return compareDateFileContent(ref, lit, compareResult -> compareResult 
>= 0);
+        return ROWS_MIGHT_MATCH;
       }
 
       @Override
       public <T> Boolean eq(BoundReference<T> ref, Literal<T> lit) {
-        return compareDateFileContent(ref, lit, compareResult -> compareResult 
== 0);
+        if (fileContent(ref)) {
+          Literal<Integer> intLit = lit.to(Types.IntegerType.get());
+          Integer fileContentId = intLit.value();
+          if (fileContentId == FileContent.DATA.id()) {
+            return manifestContentId == ManifestContent.DATA.id();
+          } else {
+            return manifestContentId == ManifestContent.DELETES.id();
+          }
+        }
+        return ROWS_MIGHT_MATCH;
       }
 
       @Override
       public <T> Boolean notEq(BoundReference<T> ref, Literal<T> lit) {
-        return compareDateFileContent(ref, lit, compareResult -> compareResult 
!= 0);
+        return ROWS_MIGHT_MATCH;

Review Comment:
   I think we can still do neq, right?  We can still extract the eq logic to a 
separate method, and then negate it here?  Let me know if im mistaken though



-- 
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-unsubscr...@iceberg.apache.org

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


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

Reply via email to