Forum Discussion
alaw005
7 years agoNew Member
Sort two lists with aligned common values
Hi, I am using PowerBI desktop with a live connection and looking to combine two ordered lists (List 1 and List 2) so that common values are aligned as shown in the combined list below. How do I do this?
| List 1 | List 2 | Combined sorted list | |||
| order | value | order | value | order | value |
| 0 | X | 0 | X | ||
| 1 | Y | 1 | Y | ||
| 0 | A | 2 | A | 2 | A |
| 1 | B | 3 | B | 3 | B |
| 4 | C | 4 | C | ||
| 5 | D | 5 | D | ||
| 6 | E | 6 | E | ||
| 2 | F | 7 | F | ||
| 3 | H | 8 | H | ||
| 4 | I | 9 | I | ||
| 5 | J | 10 | J | ||
| 7 | M | 11 | M |
3 Replies
- affanSolution Sage
Hi alaw005,
Post some data from your List 1 and List 2, what you have mentioned here is not much clear. If I take the following row from your post as a sample
List 1 List 2 Combined sorted list order value order value order value 1 B 3 B 3 B It is not clear how List1 and List2 are related. In the combined list here what have you taken from the List 1? As the value B is already in List 2.
Please state clearly what you need to acheive and also share the actual list sample data
Regards,
Affan
- alaw005New MemberSorry that not clear. I am after a new sort order so that when each list is sorted the same values have the same sort order. For example value B is order 1 in List 1 and order 3 in list B. I want to sort so B etc has the same position in both lists while retaing the existing order of items. The letters represent the sequence of stops on two different bus routes.
- affanSolution Sage
Can you share the pbix file?