I have a table with the following data in Excel:
Christian |
Florida |
1 |
Katie |
Wisconsin |
1 |
Sean |
Alabama |
2 |
Kelly |
Georgia |
2 |
Kellyn |
South Carolina |
3 |
Matt |
Texas |
3 |
What I am trying to do is find all possible combinations based on the numbers without duplicates and set them opposite to each other like this:
Christian |
Florida |
1 |
2 |
Alabama |
Sean |
Christian |
Florida |
1 |
2 |
Georgia |
Kelly |
Christian |
Florida |
1 |
3 |
South Carolina |
Kellyn |
Christian |
Florida |
1 |
3 |
Texas |
Matt |
Katie |
Wisconsin |
1 |
2 |
Alabama |
Sean |
Katie |
Wisconsin |
1 |
2 |
Georgia |
Kelly |
Katie |
Wisconsin |
1 |
3 |
South Carolina |
Kellyn |
Katie |
Wisconsin |
1 |
3 |
Texas |
Matt |
Sean |
Alabama |
2 |
3 |
South Carolina |
Kellyn |
Sean |
Alabama |
2 |
3 |
Texas |
Matt |
Kelly |
Georgia |
2 |
3 |
South Carolina |
Kellyn |
Kelly |
Georgia |
2 |
3 |
Texas |
Matt |
The VBA code I am currently working with is the following but I get too many combinations. I don't need to combine "1" with another "1" for example and I also don't want combinations shown again in the opposite direction. If a combination of "2" and "3" is displayed I don't need the same combination shown again as "3" and "2".
Bookmarks