Started to learn hibernate with examples. I have written a class "Team" that has one to many relationship with (a Collection of) players.
I need to get all the teams
- where player name is "X" (X is not the primary key of the Player table)
- where player "Y" is in
I think I have to get this done by using Criteria API or the HQL. Can someone tell how I can achieve it.