RussellSpitzer commented on a change in pull request #1772:
URL: https://github.com/apache/iceberg/pull/1772#discussion_r524358709
##########
File path: spark3/src/main/java/org/apache/iceberg/spark/source/SparkTable.java
##########
@@ -159,6 +164,11 @@ public WriteBuilder newWriteBuilder(LogicalWriteInfo info)
{
public void deleteWhere(Filter[] filters) {
Expression deleteExpr = SparkFilters.convert(filters);
+ if (deleteExpr == Expressions.alwaysFalse()) {
+ LOG.info("Skipping the delete operation as the condition is always
false");
+ return;
+ }
Review comment:
This is probably just me, but I would rather this just be an "if { log }
else { setup delete }" than an "if { log; return } setupDelete "
----------------------------------------------------------------
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]