Prova detta:
SELECT T2.name,T1.groupName
FROM Table1 T1 INNER JOIN
Table1 T2 on T1.groupID=T2.groupId2
WHERE T2.category=1
Resultat:
NAME GROUPNAME
Paul IT
Bob IT
An HR
Se resultatet i SQL Fiddle
Prova detta:
SELECT T2.name,T1.groupName
FROM Table1 T1 INNER JOIN
Table1 T2 on T1.groupID=T2.groupId2
WHERE T2.category=1
Resultat:
NAME GROUPNAME
Paul IT
Bob IT
An HR
Se resultatet i SQL Fiddle