Nesting problem, Please Help

yeidy927

New Member
Joined
May 17, 2017
Messages
2
Hi,

I an trying to solve this nesting but cant. Below is the formula that tried to use but gives me the error for too much nests. Below the formula is the table with the values. I tried a VLOOKUp but didnt work, probably I was doing it wrong.


=IF(AND($D$4="AA",I7=1),10,IF(AND($D$4="AA",I7=2),18,
IF(AND($D$4="AA",I7=3),38,IF(AND($D$4="AA",I7=4),51,
IF(AND($D$4="BB",I7=1),10,IF(AND($D$4="BB",I7=2),27,
IF(AND($D$4="BB",I7=3),38,IF(AND($D$4="BB",I7=3),46,
IF(AND($D$4="CC",I7=1),10,IF(AND($D$4="CC",I7=2),0,
IF(AND($D$4="CC",I7=3),35,IF(AND($D$4="CC",I7=4),51,
IF(AND($D$4="DD",I7=1),10,IF(AND($D$4="DD",I7=2),25,
IF(AND($D$4="DD",I7=3),55,IF(AND($D$4="DD",I7=4),0))))))))))))))))



[TABLE="class: grid, width: 100"]
<tbody>[TR]
[TD]TYPE[/TD]
[TD]AA[/TD]
[TD]BB[/TD]
[TD]CC[/TD]
[TD]DD[/TD]
[/TR]
[TR]
[TD]1[/TD]
[TD]10[/TD]
[TD]10[/TD]
[TD]10[/TD]
[TD]10[/TD]
[/TR]
[TR]
[TD]2[/TD]
[TD]18[/TD]
[TD]27[/TD]
[TD]0[/TD]
[TD]25[/TD]
[/TR]
[TR]
[TD]3[/TD]
[TD]38[/TD]
[TD]38[/TD]
[TD]35[/TD]
[TD]55[/TD]
[/TR]
[TR]
[TD]4[/TD]
[TD]51[/TD]
[TD]46[/TD]
[TD]51[/TD]
[TD]0[/TD]
[/TR]
</tbody>[/TABLE]
 

Excel Facts

Do you hate GETPIVOTDATA?
Prevent GETPIVOTDATA. Select inside a PivotTable. In the Analyze tab of the ribbon, open the dropown next to Options and turn it off
Is this what you are after?


Excel 2010
ABCDEFGHI
1TYPEAABBCCDDTypeLettersValue
21101010104BB46
321827025
4338383555
545146510
Sheet1
Cell Formulas
RangeFormula
I2=SUMPRODUCT(($A$2:$A$5=G2)*($B$1:$E$1=H2)*($B$2:$E$5))
 
Upvote 0
You can also use:

=INDEX($B$2:$E$5,MATCH(G2,$A$2:$A$5,0),MATCH(H2,$B$1:$E$1,0))

referring to the layout in post #2.
 
Upvote 0
You could use INDEX/MATCH, for example I put your little table in K1:O5 and then used this.

=INDEX(L2:O5,MATCH(I7,K2:K5,0),MATCH(D4,L1:O1,0))
 
Upvote 0

Forum statistics

Threads
1,223,907
Messages
6,175,301
Members
452,633
Latest member
DougMo

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