thswlsqls opened a new issue, #8626:
URL: https://github.com/apache/paimon/issues/8626

   **Search before asking**
   - [x] I searched in the [issues](https://github.com/apache/paimon/issues) 
and found nothing similar.
   
   **Paimon version**
   master @ 4fe3cfdd1 / 2.0-SNAPSHOT
   
   **Compute Engine**
   Spark
   
   **Minimal reproduce step**
   Query an ORC table with an `isNaN` filter, e.g. `SELECT * FROM t WHERE c = 
float('nan')`. `SparkFilterConverter` builds `PredicateBuilder.isNaN(index)`, 
which is pushed to the ORC reader. `OrcPredicateFunctionVisitor` 
(paimon-format/.../orc/filter/OrcPredicateFunctionVisitor.java) does not 
override `visitIsNaN`, so the `FunctionVisitor.visitIsNaN` default runs and 
throws `UnsupportedOperationException`. `OrcFileFormat.createReaderFactory()` 
calls `pred.visit(VISITOR)` with no try/catch, so reader creation fails and the 
query errors out.
   
   **What doesn't meet your expectations?**
   Expected: the `isNaN` filter is simply not pushed down (engine evaluates 
it), as the Parquet path already does — `ParquetFilters.convert` catches 
`UnsupportedOperationException` and skips push-down. Actual: the ORC path 
throws and the query fails.
   
   **Anything else?**
   Fix: override `visitIsNaN` to `return Optional.empty()`, matching the 
sibling unsupported ops 
(`visitStartsWith`/`visitEndsWith`/`visitContains`/`visitLike`) in the same 
class. ORC SearchArgument has no isNaN leaf.
   
   **Are you willing to submit a PR?**
   - [x] I'm willing to submit a PR!
   
   


-- 
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]

Reply via email to