I am not very good in SQL-Queries and got stuck with a query.
I have the following (simplified) table structure:
hash state group
x123 1 41
x456 2 44
x123 3 41
x456 2 44
x123 2 42
... ... ...
The hash is an identifier for a person which can be part of one or more groups.
I want to get all rows of persons wich are in more than one group. So from my example I would get all three rows of the person with the hash "x123", but none from the person with the hash "x456".
It would be nice, if anyone could help me, thanks a lot!