Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [eclipselink-users] Custom SQL for relationship

Hi! Thanks for your reply!

I would like to have the getDefaultCompany() method, but I can't code it in the entity bean, that's why I'm asking, if there is a way to query the DB (call the procedure or execute arbitrary queries) from the Entity bean (I can't inject stateless EJB for some reason -> i'm getting null for the injected bean -- What am I doing wrong?).

On Sat, Nov 27, 2010 at 1:48 PM, cinhtau <cinhtau@xxxxxxxxx> wrote:

Isn't a stored procedure database/vendor specific? Wouldn't be a contrary
approach, because my understanding of JPA is, that it is a Object Relational
Mapping technique, so that you can exchange your database.
Couldn't be retrieving the default company implemented as extra method
getDefaultCompany() be easier? Code the logic in Java. So you still can
switch to another database. Hope this will help. Maybe there are performance
View this message in context:
Sent from the EclipseLink - Users mailing list archive at

eclipselink-users mailing list

Kriván Bálint

Back to the top