posted 15 years ago
Hi people!
If I have for example two entities, Client and Product, in product entity I have a relationship with client, so I have a @ManyToOne JPA relationship.
Client
Product
- client_id
But I wonder to make an "inverse" JOIN (left) query, because its possible under native SQL using <type> JOIN ON Table (id1 = id2), but how to figure out some situation under JPA?
If I heading doing something like that I got an error:
Because 'ON' clause is not allowed up there, I know that I can use other maner like:
But sometimes I have to use like an native SQL, to JOIN a entity that don´t have directly link. Sorry If I was not clean in my ideas.
Regards!
<b>Keep your mind flowing away!</b>