I've got a many-to-many M-N relationship set up, and I need to write a finder method that selects an M that is related to a specific set of Ns.
I thought I could just create a findBy(java.util.Set s) and in EJB QL do a select ... where M.ns = s
(where M.ns is the getNs relationship)
Obviously I could call a find method that used member multiple times but this would be very inefficient.
Any suggestions greatly appreciated?
fixed by generating the query using dynamic ql.