MrDB4Excel
Active Member
- Joined
- Jan 29, 2004
- Messages
- 348
- Office Version
- 2013
- Platform
- Windows
Yes, no ifs, ands, or buts about it; this is too many ifs in one formula.
=IF(F4=$S$2,$Q$3,IF(F4=$S$3,$Q$4,IF(F4=$S$4,$Q$5,IF(F4=$S$5,$Q$6,IF(F4=$S$6,$Q$7,IF(F4=$S$7,$Q$8,IF(F4=$S$8,$Q$9,IF(F4<>$S$2,$S$9,IF(F4<>$S$3,$S$9,IF(F4<>$S$4,$S$9,IF(F4<>$S$5,$S$9,IF(F4<>$S$6,$S$9,IF(F4<>$S$7,$S$9,IF(F4<>$S$8,$S$9,IF(F4=$S$9,$S$10)))))))))))))))
There has got to be a way of making this simpler.
Notice that F4 can be = to several data points: S2, S3, S4, S5, S6, S7, and S8. One would think surely there has to be a method to check how F4 is equal to so many cells and yet be able to return the value from Q3, Q4, Q5, Q6, Q7, Q8, or Q9 that is dependent upon the values in S2, S3, S4, S5, S6, S7, or S8.
Totally confusing why this IF formula has to be so long to arrive at such simple answers. And the S2, S3, S4, S5, S6, S7, and S8 aren't the end of this formula. Just look at the rest of it: F4 being <> to S2, S3, S4, S5, S6, S7, and S8 and return a value that is based upon S9.
=IF(F4=$S$2,$Q$3,IF(F4=$S$3,$Q$4,IF(F4=$S$4,$Q$5,IF(F4=$S$5,$Q$6,IF(F4=$S$6,$Q$7,IF(F4=$S$7,$Q$8,IF(F4=$S$8,$Q$9,IF(F4<>$S$2,$S$9,IF(F4<>$S$3,$S$9,IF(F4<>$S$4,$S$9,IF(F4<>$S$5,$S$9,IF(F4<>$S$6,$S$9,IF(F4<>$S$7,$S$9,IF(F4<>$S$8,$S$9,IF(F4=$S$9,$S$10)))))))))))))))
There has got to be a way of making this simpler.
Notice that F4 can be = to several data points: S2, S3, S4, S5, S6, S7, and S8. One would think surely there has to be a method to check how F4 is equal to so many cells and yet be able to return the value from Q3, Q4, Q5, Q6, Q7, Q8, or Q9 that is dependent upon the values in S2, S3, S4, S5, S6, S7, or S8.
Totally confusing why this IF formula has to be so long to arrive at such simple answers. And the S2, S3, S4, S5, S6, S7, and S8 aren't the end of this formula. Just look at the rest of it: F4 being <> to S2, S3, S4, S5, S6, S7, and S8 and return a value that is based upon S9.