nmerchant

New Member
Joined
Mar 10, 2018
Messages
4
I'm trying to nest multiple IF statements, along with IF(AND(OR) statements within one cell. The "Premium Table" I have to use is below, along with a sample of the the worksheet. The question is: What IF statement do I enter in cell D2 to obtain the correct premium?

Premium Table


Age Range - Coverage Type - Premium Amount
Ages 18-39

<colgroup><col><col><col></colgroup><tbody>
</tbody>
Employee Only
Employee + Spouse
Employee + Child(ren)
Employee + Family
$76.05
$366.19
$366.19
$366.19
Ages 40-49Employee Only
Employee + Spouse
Employee + Child(ren)
Employee + Family
$111.20
$418.94
$418.94
$418.94
Ages 50-59Employee Only
Employee + Spouse
Employee + Child(ren)
Employee + Family
$234.32
$586.02
$586.02
$586.02
Ages 60+Employee Only
Employee + Spouse
Employee + Child(ren)
Employee + Family
$329.20
$821.56
$821.56
$821.56

<tbody>
</tbody>

ABCD
1Employee NameAgeCoveragePremium
2John Doe35Employee + Family
3Jane Smith41Employee Only
4Bob Johnson60Employee + Spouse

<tbody>
</tbody>
 

Excel Facts

Can Excel fill bagel flavors?
You can teach Excel a new custom list. Type the list in cells, File, Options, Advanced, Edit Custom Lists, Import, OK
Welcome to the Forum.

I suggest you alter the layout and use functions INDEX and MATCH, which is much easier than nesting IF statements. Copy D11 down for each Employee enquiry.

ABCDE
1Premium Table
2Age RangeEmployee OnlyEmployee + SpouseEmployee + Child(ren)Employee + Family
318$76.05$366.19$366.19$366.19
440$111.20$418.94$418.94$418.94
550$234.32$586.02$586.02$586.02
660$329.20$821.56$821.56$821.56
7
8
9
10Employee NameAgeCoveragePremium
11John Doe35Employee + Family$366.19
12Jane Smith41Employee Only$111.20
13Bob Johnson60Employee + Spouse$821.56

<colgroup><col style="width: 25pxpx"><col><col><col><col><col></colgroup><thead>
</thead><tbody>
</tbody>
Sheet37

Worksheet Formulas
CellFormula
D11=INDEX($B$3:$E$6,MATCH(B11,$A$3:$A$6,1),MATCH(C11,$B$2:$E$2,0))

<thead>
</thead><tbody>
</tbody>

<tbody>
</tbody>
 
Upvote 0
Try

Book1
ABCDEFGHI
1Employee NameAgeCoveragePremiumAge Range - Coverage Type - Premium Amount
2John Doe35Employee + Family366.19Ages 18-3918Employee Only$76.05
3Jane Smith41Employee Only111.218Employee + Spouse$366.19
4Bob Johnson60Employee + Spouse821.5618Employee + Child(ren)$366.19
518Employee + Family$366.19
6Ages 40-4940Employee Only$111.20
740Employee + Spouse$418.94
840Employee + Child(ren)$418.94
940Employee + Family$418.94
10Ages 50-5950Employee Only$234.32
1150Employee + Spouse$586.02
1250Employee + Child(ren)$586.02
1350Employee + Family$586.02
14Ages 60+60Employee Only$329.20
1560Employee + Spouse$821.56
1660Employee + Child(ren)$821.56
1760Employee + Family$821.56
Sheet1
Cell Formulas
RangeFormula
D2{=INDEX($I$2:$I$17,MATCH(VLOOKUP(B2,$G$2:$G$17,1)&C2,$G$2:$G$17&$H$2:$H$17,0))}
D3{=INDEX($I$2:$I$17,MATCH(VLOOKUP(B3,$G$2:$G$17,1)&C3,$G$2:$G$17&$H$2:$H$17,0))}
D4{=INDEX($I$2:$I$17,MATCH(VLOOKUP(B4,$G$2:$G$17,1)&C4,$G$2:$G$17&$H$2:$H$17,0))}
Press CTRL+SHIFT+ENTER to enter array formulas.
 
Upvote 0
Thank you DRSTEELE and SCOTT T. Both options work great, and save a lot of time rather than nesting multiple IF statements.
 
Upvote 0

Forum statistics

Threads
1,214,643
Messages
6,120,707
Members
448,981
Latest member
recon11bucks

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