SOLVED

Nested IF and MAX statements

Copper Contributor

I am trying to combine and IF and MAX statement. If J2=MIDPOINT I want the answer to be the higher of M2 or H2, IF J2=Entry I want the answer to be the higher of H2 or L2. I keep getting a FALSE response after the first statement. I realize that it is reading the first IF of the formula and then saying its not midpoint so it is not moving to the 2nd If statement. How do I change the formula to get past the first if statement if false and then move to the 2nd IF statement.

 

H2 J2 L2M2 Answer
$48,15010Midpoint30$29,300$36,573$43,846$48,150
$42,0163Entry30$29,300$36,573$43,846FALSE

 

=IF(J2="midpoint",MAX(H2,M2,IF(J2="entry",MAX(H2,L2))))

2 Replies
best response confirmed by VI_Migration (Silver Contributor)
Solution

@abarshak 

The closing parentheses aren't placed entirely correctly.

 

=IF(J2="midpoint",MAX(H2,M2),IF(J2="entry",MAX(H2,L2),""))

That worked, thanks.
1 best response

Accepted Solutions
best response confirmed by VI_Migration (Silver Contributor)
Solution

@abarshak 

The closing parentheses aren't placed entirely correctly.

 

=IF(J2="midpoint",MAX(H2,M2),IF(J2="entry",MAX(H2,L2),""))

View solution in original post