Hi!
Need some help with a formula to calculate a discount.
20% off all items EXCEPT the highest value item. Where 2 items are same value, only 1 gets the discount. Here's my example:
[table="width: 200, class: grid, align: left"]
[tr]
[td]price[/td]
[td]discount[/td]
[/tr]
[tr]
[td]40[/td]
[td]8[/td]
[/tr]
[tr]
[td]100[/td]
[td]0[/td]
[/tr]
[tr]
[td]100[/td]
[td]20[/td]
[/tr]
[tr]
[td]60[/td]
[td]12[/td]
[/tr]
[/table]
This seems to work when there's no duplicates: =IF(A2=MAX(A2:A4),0,A2*0.2)
But I can't get this to work when there's 2 items with the same highest value.
Any tips on how I can get this working?
Need some help with a formula to calculate a discount.
20% off all items EXCEPT the highest value item. Where 2 items are same value, only 1 gets the discount. Here's my example:
[table="width: 200, class: grid, align: left"]
[tr]
[td]price[/td]
[td]discount[/td]
[/tr]
[tr]
[td]40[/td]
[td]8[/td]
[/tr]
[tr]
[td]100[/td]
[td]0[/td]
[/tr]
[tr]
[td]100[/td]
[td]20[/td]
[/tr]
[tr]
[td]60[/td]
[td]12[/td]
[/tr]
[/table]
This seems to work when there's no duplicates: =IF(A2=MAX(A2:A4),0,A2*0.2)
But I can't get this to work when there's 2 items with the same highest value.
Any tips on how I can get this working?