Win a copy of Java 9 Revealed this week in the Features new in Java 9 forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

how we can call stored procedure in hibernate?  RSS feed

 
raminaa niilian
Ranch Hand
Posts: 551
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
Thank you for reading my post
can some one explain me how we can call and use result of an stored procedure using hibernate?

thanks
 
Mark Spritzler
ranger
Sheriff
Posts: 17309
11
IntelliJ IDE Mac Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Well, I am going to forward you off to the hibernate.org website where in the FAQ they have really good stuff for stored procedures.

There are two caveats to stored procedures.

1. You can only have one out parameter,
2. and it must be the first parameter, the out cannot be the second, third or more paramater.

As stored procedures you will basically define a mpaaing of a named-query in you config file. You can also configure your insert, update and deletes to call triggers too.

Mark
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!