Currently when I issue this SQL, it gets the distinct username.
I have some distinct usernames, which represent groups, e.g. GRP_BSN.
GRP_BSN
I would li
@bfavaretto is nice (+1 to him), but if you don't know about username prefix or they are different you can go with something like:
username
GROUP BY CASE WHEN REGEXP_LIKE(username, '^\d+$') THEN 'GRP_OTHERS' ELSE username END