Merge pull request #4534 from eugenp/jpa-fix

query type fix
This commit is contained in:
Loredana Crusoveanu 2018-06-23 22:48:15 +03:00 committed by GitHub
commit 65221919f7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -20,7 +20,7 @@ public interface PersonRepository extends MyUtilityRepository<Person, Long> {
Person findByName(@Param("name") String name);
@Query(value = "SELECT AVG(p.age) FROM person p", nativeQuery = true)
Person getAverageAge();
int getAverageAge();
@Procedure(name = "count_by_name")
long getCountByName(@Param("name") String name);