moulimukherjee commented on a change in pull request #283: Add projectStrict
for Dates and Timestamps
URL: https://github.com/apache/incubator-iceberg/pull/283#discussion_r307518808
##########
File path: api/src/main/java/org/apache/iceberg/transforms/ProjectionUtil.java
##########
@@ -52,6 +52,84 @@ private ProjectionUtil() {}
}
}
+ static <T> UnboundPredicate<T> truncateIntegerStrict(
+ String name, BoundPredicate<Integer> pred, Transform<Integer, T>
transform) {
+ int boundary = pred.literal().value();
+ switch (pred.op()) {
+ case LT:
+ // Checking if the literal is at the lower partition boundary
+ if (transform.apply(boundary - 1).equals(transform.apply(boundary))) {
+ return predicate(Expression.Operation.LT, name,
transform.apply(boundary - 1));
Review comment:
truncateLong is getting used for both Timestamps and Truncate.LONG
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]