Hmm ... See section 16.2.2 in the Hibernate 3.2 Reference:
http://www.hibernate.org/h
There are some database-specific rules that you need to follow for Oracle, Sybase, etc. But Hibernate will definitely allow you to use stored procedures for query. Since the SP call is represented as a named native query you can use the standard named query interface to get a Query object, set parameter values, and retrieve the result set. About the only thing I can think of that you /might/ not be able to do is use the paging methods (setFirstResult, setMaxResults) on it.
Jim
Main Topics
Browse All Topics





by: tedbillyPosted on 2007-09-05 at 12:55:40ID: 19835279
Probably. Many of these abstract middleware components have to go with the lowest common denominator for functionality. That's the problem with a "one size fits all solution"
So probably many of the SQL systems that Hibernate supports probably don't use stored procedures or the implementations are so different they can only support specific subsets of functionality.
If you don't plan on changing database backends why not write your own data access layer? It will give you more options, greater performance and in the long term probably scale better?