Using CriteriaBuilder.literal(Boolean.FALSE) in expressions leads to literal value being treated as TRUE instead.
See https://github.com/veselov/Standalone-JPA-Test-Demo/tree/OPENJPA-2770 for test case.
I've also attached the extracted branch here.
shows the problem. Though the cb.literal(Boolean.FALSE) is use in cb.equal(), the query is:
I changed versions to 2.4.3 and 3.0.0, the problem is still there.