Multiple IF functions with multiple conditions

RJB78

Board Regular
Joined
Aug 8, 2016
Messages
69
Office Version
  1. 365
Hello -

Problem: I am trying to get a formula to display the letter "G", "D", or "GI" based on the values of two other cells.

Example:

Symbol G,D,GI % Yes/No
A G 0.25% Y
B G 5.00% N
C G 3.00% #N/A
D D 4.00% Y
E GI 2.50% Y

Rules:

G = If Yes/No column = #N/A, then I want the G,D,GI column to display the letter 'G'. (The #N/A is from a vlookup not finding a value)
If Yes/No column = N, then I want the G,D,GI column to display the letter 'G'
If Yes/No column = Y, Then I want the G,D,GI column to display the letter 'G', only if the percentage in the % column is greater than or equal to 0 and less than .005 (between 0 and .049(mutual exclusivity))

GI = If Yes/No column = Y, then I want the G,D,GI column to display the letters 'GI', only if the percentage in the % column is greater than or equal to .005 and less than .04 (between .005 and .039)(mutual exclusivity))

D = If Yes/No column= Y, then I want the G,D,GI column to display the letter 'D', only if the percentage in the % column is greater than or equal to .04

I have some individual formulas for some of the rules, but I am not sure how to do the formula for the "G" '#N/A' rule and combine them all the rule formulas to work together.

"G" 'N' Rule: =IF(D2="N","G")
"G" 'Y' Rule: =IF(AND(D2="Y",C2>=0,C2<.005),"G")

GI Rule: =IF(AND(D2="Y",C2>=.005,C2<0.04),"GI")

D Rule: = IF(AND(D2="Y",C2>=.04),"D")

If there is no solution for the "G" 'N/A' rule I suppose I could use the iferror function to return a 'N/A'. Correct?


Thank you in advance, I really appreciate any and all assistance.
 
I also used a =iferror on the vlookup to give back the text "N/A" if the formula results in an error(#N/A). The original formula you gave me works perfectly using that
 
Upvote 0

Excel Facts

Excel Can Read to You
Customize Quick Access Toolbar. From All Commands, add Speak Cells or Speak Cells on Enter to QAT. Select cells. Press Speak Cells.

Forum statistics

Threads
1,221,310
Messages
6,159,176
Members
451,543
Latest member
cesymcox

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