Forum Discussion
Anonymous
6 years agoNot applicable
Find multiple rows with different values in another column
I have a table with a lot of articles connected to an order and also a Location, I want to find orders that contains article from more than one location, see sample below
| Order number | Article | Location |
| 12345 | A | X |
| 12345 | B | X |
| 12345 | C | Y |
| 23456 | C | Y |
| 34567 | A | X |
34567 | B | X |
| 34567 | D | X |
What I want to achive:
| Ordernumber | Multiple locations |
| 12345 | Yes |
| 23456 | No |
| 34567 | No |
What is the easiest way to do this in Power BI?
Anonymous add following measure
Multiple Lcoations = IF ( CALCULATE ( DISTINCTCOUNT( Orders[Location] ), ALLEXCEPT ( Orders, Orders[Order number] ) ) > 1, "Yes", "No" )
1 Reply
- parry2kSuper User
Anonymous add following measure
Multiple Lcoations = IF ( CALCULATE ( DISTINCTCOUNT( Orders[Location] ), ALLEXCEPT ( Orders, Orders[Order number] ) ) > 1, "Yes", "No" )