Can anyone help with this please?
I am trying to count all users in a table who are superusers (only if there is more than 1 super user).
FIELDS: 'Role' and 'Employer'
SAMPLE:ROLE - - - - - EMPLOYER - - - COUNT
Global_User | A Company Ltd | 2
Super_User | A Company Ltd | 2
I have part of this working already (if you see above it counts for every type of role).
This is the code I have got so far:
SELECT Role, Employer, COUNT(*) AS cnt
GROUP BY Role, Employer
HAVING (COUNT(Role) > 1)
However, what I'm trying to do now is only count if the 'Role' is a 'Super_User'
and ignore other roles like global user.