ColinLeeo opened a new pull request, #18982: URL: https://github.com/apache/iotdb/pull/18982
## Summary Tree-model queries such as `SELECT s1 FROM root.sg.d1 WHERE NOT (s1 > 5)` failed with: ```text This predicate contains a not! Did you forget to run this predicate through PredicateRemoveNotRewriter? ``` The analyzer left `LOGIC_NOT` in the residual predicate. The predicate was then considered pushable to a series scan, but TsFile filters cannot represent `NOT`. ## Changes - Remove `NOT` from tree-model `WHERE` and `HAVING` predicates before schema binding and pushdown. - Cover regular, `ALIGN BY DEVICE`, and templated multi-device analysis paths. - Prevent non-invertible `NOT` predicates from being pushed to scan nodes; they remain in `FilterOperator`. - Add unit and integration coverage for simple/composite `NOT`, `HAVING NOT`, `ALIGN BY DEVICE`, and multi-device Device Template queries. ## Verification - `mvn test -pl iotdb-core/datanode -am -Dtest=PredicateUtilsTest -Dsurefire.failIfNoSpecifiedTests=false` - `mvn verify -DskipUTs -Dit.test=IoTDBPredicateConversionTreeIT -DfailIfNoTests=false -Dfailsafe.failIfNoSpecifiedTests=false -pl integration-test -am -P with-integration-tests` - Spotless, Checkstyle, and RAT passed. -- 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]
