Need help with excel formula

mangoni

New Member
Joined
Sep 22, 2014
Messages
1
HI-I NEED A FORMULA THAT WILL CALCULATE THE FOLLOWING COMMISSIONS FOR EACH LINE...

If sales are 5,000,000 to 6,000,000 = 2.5%
If sales are 6,000,000 to 6,500,000 = 3.0%
If sales are 6,500,000 to 7,000,000 = 3.5%
If sales are 7,000,000+ = 4%

PLEASE HELP:)
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.
Hold down on the excitement there buddy...
Code:
=IF($A1>=7000000,4%,IF($A1>=6500000,3.5%,IF($A1>=6000000,3%,IF($A1>=5000000,2.5%,0))))
 
Upvote 0
Have a look at the VLOOKUP function.

What do you want to do if the sales are less than 5 million?
 
Upvote 0
Maybe:

=CHOOSE(IFERROR(MATCH(A1,{7000000,6500000,6000000,5000000,4999999},-1),1),0.04,0.035,0.03,0.025,0)*A1

Your values overlap, so I made some assumptions...
 
Upvote 0
=IF(AND(A1>=5000000,A1<=6000000),0.025,IF(AND(A1>=6000001,A1<=6500000),0.3,IF(AND(A1>=6500001,A1<=7000000),0.035,IF(A1>7000000,0.04,"outside range"))))

The last part of the formula says "outside range" if the value of A1 is less than 5,000,000 but you can adjust it to be whatever you'd like.
 
Upvote 0
=IF(AND(A1>=5000000,A1<=6000000),0.025,IF(AND(A1>=6000001,A1<=6500000),0.3,IF(AND(A1>=6500001,A1<=7000000),0.035,IF(A1>7000000,0.04,"outside range"))))

The last part of the formula says "outside range" if the value of A1 is less than 5,000,000 but you can adjust it to be whatever you'd like.

Fun trick, when doing things like this, always start with the criteria that will only be met once. You included the less than/greater than option, but you don't need the less than. You can sort descending values and only use the greater than.

It's like a case statement in excel/sql. Once a condition is met, it skips the remaining options. No item can be both >7,000,000 and under anything else. So anything over 7,000,000 is attributed a value and skipped.

The same for 6,500,000. If an item is over 6,500,000 AND over 7,000,000, it has already been assigned to the 7,000,000 value!
 
Upvote 0

Forum statistics

Threads
1,213,543
Messages
6,114,237
Members
448,555
Latest member
RobertJones1986

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top