I need to use raw SQL within a Spring Data Repository, is this possible? Everything I see around @Query is always entity based.
@Query
The @Query annotation allows to execute native queries by setting the nativeQuery flag to true.
Quote from Spring Data JPA reference docs.
Also, see this section on how to do it with a named native query.
1.4m articles
1.4m replys
5 comments
57.0k users