-
1. Re: EJB 3.0 and Stored Procedures
epbernard May 3, 2006 2:24 PM (in response to tvanbuskirk)How is a stored procedure slower than a prepared statement?
-
2. Re: EJB 3.0 and Stored Procedures
tvanbuskirk May 4, 2006 9:11 PM (in response to tvanbuskirk)Hi Emmanuel,
Thank you for your reply. To be honest, it was always an assumption (so shame on me for assuming!).
Do you have any numbers or a link I can visit to see the performance differences?
Thanks! -
3. Re: EJB 3.0 and Stored Procedures
epbernard May 4, 2006 9:20 PM (in response to tvanbuskirk)it depends on your driver / connection pool / DB, so it's better to actullay write a decent benchmark at home.
-
4. Re: EJB 3.0 and Stored Procedures
tvanbuskirk May 4, 2006 9:32 PM (in response to tvanbuskirk)Thanks, I'd like to write the benchmark, but I think I've gotten off topic.
I'm still trying to figure out how to call the stored procedure from my EntityManager. Can you help me with that?
Thanks in advance! -
5. Re: EJB 3.0 and Stored Procedures
tvanbuskirk May 5, 2006 4:01 PM (in response to tvanbuskirk)I found the "@NamedQuery" annotation, and that will bind my query to a bean at execution. Will this be as fast as a stored procedure?
Also, still wondering about stored procs in EJB 3.0. I know you can do a "callable" in Hibernate 3 to call a stored proc. Is there an annotation or something in EJB 3.0 that is similar to this?
Thanks in advance!
P.S. I'm using mysql-connector-j w/ a mysql datasource.