This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreDid you hear? There's a new SQL AI Developer certification (DP-800). Start preparing now and be one of the first to get certified. Register now
Hi,
I would like to merge two data sets into a new dataset based on a squence of numbers and the overall category, however that squence is often out of order between the two datasets. Is there a query to fix this? Underneath is a sample of that data where Category 1 and Squence 1 represents columns in the first dataset and Category 2 and Squence 2 represents columnd in the second data set. The last table is the destired outcome.
| Category 1 | Squence 1 |
| Name1 | G0463 |
| Name2 | G0463 |
| Name3 | G0463 |
| Name1 | 97110 |
| Name4 | G0463 |
| Name2 | 97110 |
| Name3 | 97110 |
| Name3 | 80050;80061;83036;84153;81003 |
| Name1 | 90686;90471 |
| Name1 | 73030 |
| Category 2 | Squence 2 |
| Name1 | G0463 |
| Name2 | G0463 |
| Name3 | G0463 |
| Name1 | 97110 |
| Name4 | G0463 |
| Name4 | 97110 |
| Name3 | 97110 |
| Name3 | 80061;83036;84153;81003;80050 |
| Name1 | 90686;90471 |
| Name2 | 73030 |
| Category Want | Squence Want |
| Name1 | G0463 |
| Name2 | G0463 |
| Name3 | G0463 |
| Name1 | 97110 |
| Name4 | G0463 |
| Name3 | 97110 |
| Name1 | 90686;90471 |
| Name3 | 80050;80061;83036;84153;81003 |
Appologies, the Sequence:
| Name3 | 80050;80061;83036;84153;81003 |
Should also come up as a match even though it's out of order in the seccond table.
That worked! Is there a way to bring in the squence from table 1?
Thank you for your help.
Thank you! I was looking for somthing more like this where the squence values from both table are in either of of the tables or a new table. Looking somthing like this.
| Category Want | Squence 1 | Squence 2 |
| Name1 | G0463 | G0463 |
| Name2 | G0463 | G0463 |
| Name3 | G0463 | G0463 |
| Name1 | 97110 | 97110 |
| Name4 | G0463 | G0463 |
| Name3 | 97110 | 97110 |
| Name1 | 90686;90471 | 90686;90471 |
| Name3 | 80050;80061;83036;84153;81003 | 80061;83036;84153;81003; 80050 |
Check out the April 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 3 | |
| 3 | |
| 3 | |
| 2 | |
| 2 |
| User | Count |
|---|---|
| 7 | |
| 5 | |
| 4 | |
| 4 | |
| 3 |