I have a table like below:
user_id number
1 10
2 17
1 12
2 18
I mean one user can have more than one row. I have to reach following result:
user_id number
1 12
2 18
How can I achive this with hibernate criteria?