I still can't get this formula right(IF/AND/OR)

Phoebe8178

New Member
Joined
Sep 22, 2002
Messages
17
This is the formula that I have written in my cell, but it won't accept it. =IF(OR(AND(A4<=50000,d4<3),0.25,AND(a4<=50000,d4>3),0.0625,AND(a4>50000,a4<=300000,d4<3),0.25,AND(a4>50000,a4<=300000,d4>3),0.0625,AND(a4>300000,d4<3),0.4375,AND(a4>300000,d4>3),0.25))
I'm comparing compensation amounts with years of service and the percentage that is associated with it. I am just starting to learn all of these functions and I am getting very confused. It's probably a simple error, but I can not figure it out for the life of me. Thank you!!!!!
This message was edited by Phoebe8178 on 2002-10-08 10:28
 

Excel Facts

Links? Where??
If Excel says you have links but you can't find them, go to Formulas, Name Manager. Look for old links to dead workbooks & delete.
I don't think you need the OR statement

=IF(AND(A4<=50000,D4<3),0.25,IF(AND(A4<=50000,D4>3),0.0625,IF(AND(A4>50000,A4<=300000,D4<3),0.25,IF(AND(A4>50000,A4<=300000,D4>3),0.0625,IF(AND(A4>300000,D4<3),0.4375,IF(AND(A4>300000,D4>3),0.25))))))
 
Upvote 0
On 2002-10-08 10:25, Phoebe8178 wrote:
This is the formula that I have written in my cell, but it won't accept it. =IF(OR(AND(A4<=50000,d4<3),0.25,AND(a4<=50000,d4>3),0.0625,AND(a4>50000,a4<=300000,d4<3),0.25,AND(a4>50000,a4<=300000,d4>3),0.0625,AND(a4>300000,d4<3),0.4375,AND(a4>300000,d4>3),0.25))
I'm comparing compensation amounts with years of service and the percentage that is associated with it. I am just starting to learn all of these functions and I am getting very confused. It's probably a simple error, but I can not figure it out for the life of me. Thank you!!!!!
This message was edited by Phoebe8178 on 2002-10-08 10:28

Consider something like

=IF(OR(AND(A4<=50000,D4<3),AND(A4>50000,A4<=300000,D4<3),AND(A4>300000,D4>3)),0.25,IF(OR(AND(A4<=50000,D4>3),AND(A4>50000,A4<=300000,D4>3)),0.0625,IF(AND(A4>300000,D4<3),0.4375,"")))

I did not check the logic or reasonableness of the formula.

1. You should check the validity of each section of the formula.
2. What if D4 =3?
This message was edited by Dave Patton on 2002-10-08 11:03
 
Upvote 0
Another great suggestion, I will try both and again---THANK YOU SOOOOO MUCH!!!! These formulas can be so frustrating sometimes!
 
Upvote 0

Forum statistics

Threads
1,214,827
Messages
6,121,809
Members
449,048
Latest member
greyangel23

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