If you are finding the TRUNC function is not working with your JPQL, then here is the solution. You can alternately use the FUNC function of JPQL to translate the TRUNC into JPQL. Here is the example.
Hope this little trick will work with you.
Select o from Example o where FUNC('TRUNC', o.date) = ...
Hope this little trick will work with you.
Comments
FUNC('TRUNC', o.date, 'IW')
It is throwing exception.