Forum Discussion
Multiple if
Why can you not use IF?
Are you aware of IFS? It covered multiple multiple conditions.
Tell us more what your situation is.
- Asmaa950Jun 06, 2020Copper Contributor
mathetesthis formula does not work
=IF(V10<15000/12,0,IF(V10<30000/12,"(V10-(15000/12))*2.5%",IF(V10<45000/12,"((V10-(30000/12))*10%)+(375/12)",IF(V10<60000/12,((V10-(45000/12))*15%)+(1875/12),IF(V10<200000/12,((V10-(60000/12))*20%)+(4125/12),IF(V10<400000/12,((V10-(200000/12))*22.5%)+(32125/12),IF(V10<600000/12,"((V10-(400000/12))*25%)+(77125/12)",IF(V10<700000/12,"((V10-(400000/12))*25%)+(77500/12)",IF(V10<800000/12,((V10-(400000/12))*25%)+(79750/12),IF(V10<900000/12,((V10-(400000/12))*25%)+(82000/12),IF(V10<1000000/12,((V10-(400000/12))*25%)+(85000/12),IF(V10>1000000/12,((V10-(400000/12))*25%)+(90000/12),0))))))))))))
- mathetesJun 06, 2020Silver Contributor
When a formula like that doesn't work--and "doesn't work" doesn't tell us what does happen, what error message you're getting, or is it not an error message at all, just not the result that you expect?--I will usually take each individual condition and ensure first that it works separately.
For the most part, just for intelligibility, we're better served by not trying to build nested formulas quite so deeply nested. Most texts on Excel warn against them. It's fun to make them work, perhaps, but trying to go back and diagnose or fix when it "doesn't work" is always frustrating.
I can't test the formula without the full sheet, and (frankly) I'm not going to devote the time to try to parse it. You clearly know the syntax of IF; it's not likely the case that IF per se isn't working, more that there's some relationship in there that causes failure...breaking it apart into separate IFs is what I'd recommend you do.
- SergeiBaklanJun 06, 2020Diamond Contributor
Just in case, that's duplication of https://techcommunity.microsoft.com/t5/resources-and-community/multiple-conditional-if/m-p/1445505#M875