Amit Makhija

Amit Makhija

  • NA
  • 227
  • 3.3k

Select multiple rows with matching id(s)

Dec 10 2018 6:32 AM
I tried for hours and read many posts but I still can't figure out how to handle this request:
 
I have a table like this:
 
roleid      comid
11             A
12             A
11             B
12             B
13             B
 
I would like to select the roleid that occurs more than once with the different comid.
 
I wanna output should be something like:
roleid      comid
11             A,B
12             A,B
13             B

Answers (4)