spring-data-jpa
spring-data-jpa copied to clipboard
BadJpqlGrammarException with attribute 'date'
Could be similar to https://github.com/spring-projects/spring-data-jpa/issues/3062.
Spring Data JPA throws BadJpqlGrammarException: Line 1:46 no viable alternative at input 'e.embeddedId.date'; Bad JPQL grammar [SELECT e FROM Entity e WHERE e.embeddedId.date BETWEEN :from AND :to]
@Query("SELECT e FROM Entity e WHERE e.embeddedId.date BETWEEN :from AND :to")
List<Entity> findAllEntitiesBetween(@Param("from") LocalDate from, @Param("to") LocalDate to);
We are using the latest Spring Boot BOM 3.1.2 with Spring Data JPA 3.1.2.
Merged to main and backported to 3.1.x.