arcadedb
arcadedb copied to clipboard
fix: comparison of empty strings with like
What does this PR do?
This change fixes and tests the case of comparing two empty strings "" with LIKE, ie: SELECT ("" LIKE ""),
see https://sqlfiddle.com/postgresql/online-compiler?id=357ca34a-0b9f-428d-8f17-10d3202e8a38 for comparison.
Related issues
https://github.com/ArcadeData/arcadedb/issues/1580
Additional Notes
The changed file contains a TODO, https://github.com/ArcadeData/arcadedb/blob/main/engine/src/main/java/com/arcadedb/query/sql/executor/QueryHelper.java#L35 which could be fixed to with this PR, but I haven't found a way yet to improve it.
Checklist
- [X] I have run the build using
mvn clean packagecommand - [X] My unit tests cover both failure and success scenarios