Spreadsheet: 878197d1725259713-filtering-duplicate-values-mosom-20-365-spill-aligw
Sheet: Sheet1

Data that I have: |  |  |  |  |  |  |  | I can get the duplicate rows up to the user's first row: |  |  |  |  |  |  |  |  |  | I can then list them better: |  |  |  |  |  |  |  |  |  | What I want (unique users, unique roles):
Anakin | Skywalker |  | Role 1 | Role 2 | Role 3 |  |  |  | Role 4 | 0 | 0 |  |  |  |  |  |  |  | Role 1 | Role 2 | Role 3 | Role 2 | Role 4 |  |  |  |  |  | Role 1 | Role 2 | Role 3 | Role 4
Anakin | Skywalker |  | Role 2 | Role 4 |  |  |  |  |  |  |  |  |  |  |  |  |  |  | Role 2 | Role 4 |  |  |  |  |  |  |  | Princess Leia | Role 1 | Role 2 | Role 3 | Role 4
Princess | Leia |  | Role 1 | Role 2 | Role 3 | Role 4 |  |  | Role 4 | 0 | 0 |  |  |  |  |  |  |  | Role 1 | Role 2 | Role 3 | Role 4 | Role 3 | Role 4 |  |  |  | Han Solo | Role 1 | Role 2 | Role 3 | Role 4 | Role 5
Princess | Leia |  | Role 3 | Role 4 |  |  |  |  |  |  |  |  |  |  |  |  |  |  | Role 3 | Role 4 |  |  |  |  |  |  |  | [NAME] | Role 1 | Role 2 | Role 3 | Role 4 | Role 5 | Role 6
Han | Solo |  | Role 1 |  |  |  |  |  | Role 3 | Role 4 | 0 |  |  | Role 3 | Role 5 | 0 |  |  | Role 1 | Role 2 | Role 3 | Role 4 | Role 2 | Role 3 | Role 5 |  |  | Obi [NAME] | Role 1 | Role 2
Han | Solo |  | Role 2 | Role 3 | Role 4 |  |  |  | Role 3 | Role 5 | 0 |  |  |  |  |  |  |  | Role 2 | Role 3 | Role 4 | Role 2 | Role 3 | Role 5 |  |  |  | [NAME] | Role 3 | Role 4
Han | Solo |  | Role 2 | Role 3 | Role 5 |  |  |  |  |  |  |  |  |  |  |  |  |  | Role 2 | Role 3 | Role 5
[NAME] | Skywalker |  | Role 5 | Role 6 |  |  |  |  | Role 3 | 0 | 0 |  |  | Role 3 | Role 4 | Role 7 |  |  | Role 5 | Role 6 | Role 1 | Role 3 | Role 2 | Role 3 | Role 4 | Role 7
[NAME] | Skywalker |  | Role 1 | Role 3 |  |  |  |  | Role 3 | Role 4 | Role 7 |  |  |  |  |  |  |  | Role 1 | Role 3 | Role 2 | Role 3 | Role 4 | Role 7
[NAME] | Skywalker |  | Role 2 | Role 3 | Role 4 | Role 7 |  |  |  |  |  |  |  |  |  |  |  |  | Role 2 | Role 3 | Role 4 | Role 7
Obi Wan | Kenobi |  | Role 1 | Role 2 |  |  |  |  |  |  |  |  |  |  |  |  |  |  | Role 1 | Role 2
[NAME] | [NAME] |  | Role 3 | Role 4 |  |  |  |  |  |  |  |  |  |  |  |  |  |  | Role 3 | Role 4
the data lists users' access in different areas, and thus has duplicates, both in users and in roles. |  |  |  |  |  |  |  | I've managed to bring any roles from duplicates users up to the first instance of the user, but |  |  |  |  |  |  |  |  |  | I've managed to list the roles without the spaces, but the duplicate users and the duplicate roles are still there |  |  |  |  |  |  |  |  |  | What I want is a list of unique users, with their unique list of roles. The order of the roles doesn’t matter.
 |  |  |  |  |  |  |  | duplicates roles are still there
 |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  | Role 1 | Role 2 | Role 3 | Role 4
 |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  | Princess Leia | Role 1 | Role 2 | Role 3 | Role 4
 |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  | Han Solo | Role 1 | Role 2 | Role 3 | Role 4 | Role 5
 |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  | [NAME] | Role 1 | Role 2 | Role 3 | Role 4 | Role 5 | Role 6 | Role 7
 |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  | Obi [NAME] | Role 1 | Role 2
 |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  |  | [NAME] | Role 3 | Role 4