Am new to SPRING with JPA techniques.
am trying to call the stored procedure which is written in mysql 5. when i am trying to get the data using stored procedure cal
Use EntityManager.createNativeQuery() instead. I don't think it's possible to call a stored procedure through a JPA query.
public List doInJpa(EntityManager em) throws PersistenceException {
javax.persistence.Query query=em.createNativeQuery("call st_proc_getusers()");
return query.getResultList();
}
You could also use @NamedNativeQuery.