I need the possibility to retrieve the orders for the past 6 months for my backend application.
@Query("Select ord From orders ord WHERE ord.created_date <= (current_date - INTERVAL '6 months')")
List<Order> findOrders();
unexpected token: INTERVAL near line 1, column 70 [Select ord From orders ord WHERE ord.created_date <= (current_date INTERVAL '6 months')
After some research , I've found out that JPA does not support the INTERVAL definition. Is there a workaround for archiving this particularly function ?