Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
The article you are trying to access is permanently deleted.
Hello
I need your help to match the data from my table as
Equals
Is it possible to create a measure to get the above results?
Result
Type | Order No | Order Date | Delivery Date | Result |
1 | 8767879 | 10-Jan-22 | 22-Jan-22 | Matched |
2 | 8767879 | 10-Jan-22 | 22-Jan-22 | Matched |
1 | 987190 | 12-Jan-22 | 24-Jan-22 | Matched |
2 | 987190 | 12-Jan-22 | 24-Jan-22 | Matched |
1 | 187979 | 12-Jan-22 | 24-Jan-22 | Missing |
1 | 12657 | 20-Feb-22 | 04-Mar-22 | Unmatched |
2 | 12657 | 20-Feb-23 | 04-Mar-23 | Unmatched |
1 | 3121 | 19-Jun-22 | 29-Jun-22 | Unmatched |
2 | 3121 | 19-Jun-22 | 30-Jun-22 | Unmatched |
Thanks
Solved! Go to Solution.
Hi @gauravnarchal , try this calculate column:
Result = var order_p=CALCULATE(count(Table1[Order No]),ALLEXCEPT(Table1,Table1[Order No]))
var order_date_p=CALCULATE(DISTINCTCOUNT(Table1[Order Date]),ALLEXCEPT(Table1,Table1[Order No]))
var delivery_date_p=CALCULATE(DISTINCTCOUNT(Table1[Delivery Date]),ALLEXCEPT(Table1,Table1[Order No]))
return
SWITCH(
TRUE(),
order_p=1, "Missing",
order_p=2 && order_date_p=1 && delivery_date_p=1, "Matched",
"Unmatched"
)
The result:
Best regards
Hi @gauravnarchal , try this calculate column:
Result = var order_p=CALCULATE(count(Table1[Order No]),ALLEXCEPT(Table1,Table1[Order No]))
var order_date_p=CALCULATE(DISTINCTCOUNT(Table1[Order Date]),ALLEXCEPT(Table1,Table1[Order No]))
var delivery_date_p=CALCULATE(DISTINCTCOUNT(Table1[Delivery Date]),ALLEXCEPT(Table1,Table1[Order No]))
return
SWITCH(
TRUE(),
order_p=1, "Missing",
order_p=2 && order_date_p=1 && delivery_date_p=1, "Matched",
"Unmatched"
)
The result:
Best regards
Hi @Bifinity_75 - The solution provided by you did work. There is a small change that is needed to the DAX.
I want to count the order no of each order serial, so have to change the below part
The reason I would need to count the order no of each order serial is that the order numbers are getting duplicated in my data so have to narrow down the count based on the order serial.
I have attached the updated PBIX which is having the order serial. Click Here
Thank you for your help.
Check out the July 2025 Power BI update to learn about new features.
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
User | Count |
---|---|
71 | |
70 | |
43 | |
31 | |
26 |
User | Count |
---|---|
89 | |
49 | |
44 | |
38 | |
37 |