Microsoft Fabric Community Conference 2025, March 31 - April 2, Las Vegas, Nevada. Use code FABINSIDER for a $400 discount.
Register nowGet inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.
There is likely a simple solution to this but I cant seem to find it. I'd like to create a card that shows which product is the highest selling based on sales quantity.
For example
Transaction number | Product | Units Sold |
1 | Toy | 2 |
2 | Snack | 4 |
3 | Toy | 3 |
4 | Beverage | 1 |
5 | Snack | 5 |
In this case, id like to have a card that shows "Snack" given that in this table it has the largest quantity sold.
I'd also like to do the reverse, a card that shows the lowest selling product, so "Beverage"
Solved! Go to Solution.
pls try this
Measure =
VAR tbl=SUMMARIZE('Table','Table'[Product],"_sum",sum('Table'[Units Sold]))
VAR _max=maxx(tbl,[_sum])
return maxx(FILTER(tbl,_max=[_sum]),'Table'[Product])
Measure2 =
VAR tbl=SUMMARIZE('Table','Table'[Product],"_sum",sum('Table'[Units Sold]))
VAR _min=minx(tbl,[_sum])
return maxx(FILTER(tbl,_min=[_sum]),'Table'[Product])
Proud to be a Super User!
pls try this
Measure =
VAR tbl=SUMMARIZE('Table','Table'[Product],"_sum",sum('Table'[Units Sold]))
VAR _max=maxx(tbl,[_sum])
return maxx(FILTER(tbl,_max=[_sum]),'Table'[Product])
Measure2 =
VAR tbl=SUMMARIZE('Table','Table'[Product],"_sum",sum('Table'[Units Sold]))
VAR _min=minx(tbl,[_sum])
return maxx(FILTER(tbl,_min=[_sum]),'Table'[Product])
Proud to be a Super User!
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code FABINSIDER for a $400 discount!
Check out the February 2025 Power BI update to learn about new features.
User | Count |
---|---|
126 | |
113 | |
71 | |
65 | |
46 |