How to map the result set of a JPA NativeQuery to a POJO using SqlResultSetMapping

@SqlResultSetMapping annotation should not be put on a POJO. Put it at (any) @Entity class. “Unknown SqlResultSetMapping [foo]” tells you, that JPA provider doesn’t see any mapping under name ‘foo’. Please see another answer of mine for the correct example

Leave a Comment