A customer needs help with a SQL query to get list of Users and the Groups they are in.
The table USGR represents the relation between user and user groups
The following select give you all users and its user groups
select a.OH_Client, a.OH_NAME, b.OH_Name
from
OH a,
oh b,
USRG
where
a.OH_IDNR = USRG_USR_Idnr and
b.OH_Idnr = USRG_USG_Idnr
order by 3