I have data like this:
- Person A has a relationship with Person B, and person A has a relationship with Person C
- Person B has a relationship with D and E.
I want to view result in group in SQL Server (A, B ,C,...) and (B,D,E,...)
I have tried looking recursive but not getting this to implement.
I need to do this in SQL.
Thanks for the help .

