In Part 1 of our Excel IF function tutorial, we started to learn the nuts and bolts of the Excel IF function. As you remember, we discussed a few IF formulas for numbers, dates and text values as well as how to write an IF statement for blank and non-blank cells.

However, for powerful data analysis, you may often need to evaluate multiple conditions at a time, meaning you have to construct more sophisticated logical tests using multiple IF functions in one formula. The formula examples that follow below will show you how to do this correctly. You will also learn how to use Excel IF in array formulas and learn the basics of the IFEFFOR and IFNA functions.

In summary, there can be 2 basic types of multiple conditions - with AND and OR logic. Consequently, your IF function should embed an AND or OR function in the logical test, respectively.

- AND function. If your logical test contains the AND function, Microsoft Excel returns TRUE if
**all the conditions**are met; otherwise it returns FALSE. - OR function. In case you use the OR function in the logical test, Excel returns TRUE if
**any of the conditions**is met; FALSE otherwise.

To better illustrate the point, let's have a look at a few IF examples with multiple conditions.

Suppose, you have a table with the results of two exam scores. The first score, stored in column C, must be equal to or greater than 20. The second score, listed in column D, must be equal to or exceed 30. Only when both of the above conditions are met, a student passes the final exam.

The easiest way to make a proper formula is to write down the condition first, and then incorporate it in the logical_test argument of your IF function:

Condition: AND(B2>=20, C2>=30)

IF/AND formula:

`=IF((AND(C2>=20, D2>=30)), "Pass", "Fail")`

Easy, isn't it? The formula tells Excel to return "Pass" if a value in column C >=20 AND a value in column D >=30. Otherwise, the formula returns "Fail". The screenshot below proves that our Excel IF /AND function is correct:

In practice, a seemingly correct IF / AND formula may result in an error because of this specificity. For example, the below formula will return "Divide by Zero Error" (#DIV/0!) if cell A2 is equal to 0:

`=IF(AND(A2<>0,(1/A2)>0.5),"Good", "Bad")`

The avoid this, you should use a nested IF function:

`=IF(A2<>0, IF((1/A2)>0.5, "Good", "Bad"), "Bad")`

You use the combination of IF & OR functions in a similar way. The difference from the IF / AND formula discussed above is that Excel returns TRUE if **at least one** of the specified conditions is met.

So, if we modify the above formula in the following way:

`=IF((OR(C2>=20, D2>=30)), "Pass", "Fail")`

Column E will have the "Pass" mark if either the first score is equal to or greater than 20 **OR** the second score is equal to or greater than 30.

As you see in the screenshot below, our students have a better chance to pass the final exam with such conditions (Scott being particularly unlucky failing by just 1 point : )

More formula examples can be found in Excel IF OR functon.

In case you have to evaluate your data based on several sets of multiple conditions, you will have to employ both AND & OR functions at a time.

In the above table, suppose you have the following criteria to evaluate the students' success:

- Condition 1: column C>=20 and column D>=25
- Condition 2: column C>=15 and column D>=20

If either of the above conditions is met, the final exam is deemed passed, otherwise - failed.

The formula might seem tricky, but in a moment, you will see that it is not! You just have to express two conditions as AND statements and enclose them in the OR function since you do not require both conditions to be met, either will suffice:

`OR(AND(C2>=20, D2>=25), AND(C2>=15, D2>=20)`

Finally, use the above OR function as the logical test in the IF function and supply value_if_true and value_if_false arguments. As the result, you will get the following IF formula with multiple AND / OR conditions:

`=IF(OR(AND(C2>=20, D2>=25), AND(C2>=15, D2>=20)), "Pass", "Fail")`

The screenshot below indicates that we've got the formula right:

Naturally, you are not limited to using only two AND/OR functions in your Excel IF formulas. You can use as many logical functions as your business logic requires, provided that:

- In Excel 2016, 2013, 2010 and 2007, your formula includes no more than 255 arguments, and the total length of the formula does not exceed 8,192 characters.
- In Excel 2003 and lower, you can use up to 30 arguments and the total length of your formula shall not exceed 1,024 characters.

If you need to create more elaborate logical tests for your data, you can include additional IF statements in the value_if_true and value_if_false arguments of your Excel IF formulas. These multiple IF functions are called **nested IF functions** and they may prove particularly useful if you want your formula to return 3 or more different results.

Here's a typical example: suppose you want not simply to qualify the students' results as Pass/Fail, but define the total score as "*Good*", "*Satisfactory*" and "*Poor*". For instance:

- Good: 60 or more (>=60)
- Satisfactory: between 40 and 60 (>40 and <60)
- Poor: 40 or less (<=40)

To begin with, you can add an additional column (E) with the following formula that sums numbers in columns C and D:

`=C2+D2`

And now, let's write a nested IF function based on the above conditions. It's considered a good practice to start with the most important condition and make your functions as simple as possible. Our Excel nested IF formula is as follows:

`=IF(E2>=60, "Good", IF(E2>40, "Satisfactory", "Poor "))`

As you see, just one nested IF function is sufficient in this case. Naturally, you can nest more IF functions if you want to. For example:

`=IF(E2>=70, "Excellent", IF(E2>=60, "Good", IF(E2>40, "Satisfactory", "Poor ")))`

The above formula adds one more conditions - the total score of 70 points and more is qualified as "Excellent".

For more information about Excel IF with multiple conditions, please see How to use nested IF in Excel.

Like other Excel functions, IF can be used in array formulas. You may need such a formula if you want to evaluate every element of the array when the IF statement is carried out.

For example, the following array SUM/IF formula demonstrates how you can sum cells in the specified range based on a certain condition rather than add up the actual values:

`=SUM(IF(B1:B5<=1,1,2))`

The formula assigns a certain number of "points" to each value in column B - if a value is equal to or less than 1, it equates to 1 point; and 2 points are assigned to each value greater than 1. And then, the SUM function adds up the resulting 1's and 2's, as shown in the screenshot below.

Earlier in this tutorial, we've discussed a few IF formula examples demonstrating how to use the Excel IF function with logical functions AND and OR. Now, let's see what other Excel functions can be used with IF and what benefits this gives to you.

When discussing nested IF functions, we wrote the formula that returns different ranking (Excellent, Good, Satisfactory or Poor) based on the total score of each student. As you remember, we added a new column with the formula that calculates the total of scores in columns C and D.

But what if your table has a predefined structure that does not allow any modifications? In this case, instead of adding a helper column, you could add values directly in your If formula, like this:

`=IF((C2+D2)>=60, "Good", IF((C2+D2)=>40, "Satisfactory", "Poor "))`

Okay, but what if your table contains a lot of individual scores, say 5 different columns or more? Summing so many figures directly in the IF formula would make it enormously big. An alternative is embedding the SUM function in the IF's logical test, like this:

`=IF(SUM(C2:F2)>=120, "Good", IF(SUM(C2:F2)>=90, "Satisfactory", "Poor "))`

In a similar fashion, you can use other Excel functions in the logical test of your IF formulas:

**IF and AVERAGE:**

`=IF(AVERAGE(C2:F2)>=30,"Good",IF(AVERAGE(C2:F2)>=25,"Satisfactory","Poor "))`

The formulas retunes "Good" if the average score in columns C:F is equal to or greater than 30, "Satisfactory" if the average score is between 29 and 25 inclusive, and "Poor" if less than 25.

**IF and MAX/MIN:**

To find the highest and lowest scores, you can use the MAX and MIN functions, respectively. Assuming that column F is the total score column, the below formulas work a treat:

MAX: `=IF(F2=MAX($F$2:$F$10), "Best result", "")`

MIN: `=IF(F2=MIN($F$2:$F$10), "Worst result", "")`

If you'd rather have both the Min and Max results in the same column, you can nest one of the above functions in the other, for example:

`=IF(F2=MAX($F$2:$F$10) ,"Best result", IF(F2=MIN($F$2:$F$10), "Worst result", ""))`

In a similar manner, you can use the IF function with your custom worksheet functions. For example, you can use it with the GetCellColor / GetCellFontColor functions to return different results based on a cell color.

In addition, Excel provides a number of special IF functions to analyze and calculate data based on different conditions.

For example, to count the occurrences of a text or numeric value based on a single or multiple conditions, you can use COUNTIF and COUNTIFS, respectively. To find out a sum of values based on the specified condition(s), use the SUMIF or SUMIFS functions. To calculate the average according to certain criteria, use AVERAGEIF or AVERAGEIFS.

For the detailed step-by-step formula examples, check out the following tutorials:

- How to use the COUNTIF in Excel
- Using Excel COUNTIFS and COUNTIF with multiple conditions
- SUMIF in Excel - formula examples to conditionally sum cells
- How to use Excel SUMIFS and SUMIF with multiple criteria

You already know a way to spot blank and non-blank cells using the ISBLANK function. Microsoft Excel provides analogous functions to identify text and numeric values - ISTEXT and ISNUMBER, respectively.

Here's is example of the nested Excel IF function that returns "Text" if cell B1 contains any text value, "Number" if B1 contains a numeric value, and "Blank" if B1 is empty.

`=IF(ISTEXT(B1), "Text", IF(ISNUMBER(B1), "Number", IF(ISBLANK(B1), "Blank", "")))`

Sometimes, you can achieve the desired result by embedding the IF statement in some other Excel function, rather than using another function in a logical test.

Here's another way how you can use the CONCATINATE and IF functions together:

`=CONCATENATE("You performed ", IF(C1>5,"fantastic!", "well"))`

I believe you hardly need any explanation of what the formula does, especially looking at the screenshot below:

Both of the functions, IFERROR and IFNA, are used to trap errors in Excel formulas and replace them with another calculation, predefined value or text message. In earlier Excel versions, you can use the IF ISERROR and IF ISNA combinations instead.

The difference is that IFERROR and ISERROR handle all possible Excel errors, including #VALUE!, #N/A, #NAME?, #REF!, #NUM!, #DIV/0!, and #NULL!. While IFNA and ISNA specialize solely in #N/A errors.

Here is the simplest example of the IFERROR formula:

`=IFERROR(B2/C2, "Sorry, an error has occurred")`

As you see in the screenshot above, column D displays the quotient of the division of a value in column B by a value in column C. You can also see two error messages in cells D2 and D5 because everyone knows that you cannot divide a number by zero.

In some cases, however, you may not want to trap all errors, but rather test the condition causing a specific error. For example, to replace a divide by zero error with your own message, use the following IF formula:

`=IF(C2=0, "Sorry, an error has occurred", B2/C2)`

And that's all I have to say about using the IF function in Excel. I thank you for reading and hope to see you on our blog next week!

Excel formulas
CSV
Excel functions
Print
Financial functions
Vlookup
Merge data in Excel
SumIf
CountIf
Excel Compare
If statement
Excel Charts
Pivot Table
Conditional formatting
Excel formatting
Excel duplicates
Excel date
Excel tips
Excel macro
Outlook
Google Sheets
Outlook duplicates
Outlook templates

## 2,729 responses to "Excel IF statement with multiple AND/OR conditions, nested IF formulas, and more"

I am trying to do a formula:

Column j minus column L but only if there is a value in L if there is no value then it equals 0.

I need a formula that essentially says the following:

if a2 is " a" and b2 is "no" c2 is 1

if a2 is "a" and b2 is "yes" c2 is 2

if a2 is "b" and b2 is "no" c2 is 3

if a2 is "b" and b2 is "yes" c2 is 4

I tried if(or(and) but I can only get two results with that formula. Can someone help?

=IF((AND(A2="A",B2="NO")),1,IF((AND(A2="A",B2="YES")),2,IF((AND(A2="B",B2="NO")),3,IF((AND(A2="B",B2="YES")),4,0))))

=IF(A2="a", IF(B2="no",1,2), IF(A2="b", IF(B2="no",3,4)))

Should be typed in C2

=IF(OR(AND(A2=a,B2=no)),"1",IF(OR(AND(A2=a,B2=yes)),"2",IF(OR(AND(A2=b,B2=no),"3",IF(OR(AND(A2=b,B2=yes)),"4"))))

Hello,

If we understand your task correctly, you need to create a few helper columns:

- Column G: G1 - "a", G2 - "a", G3 - "b", G4 - "b"

- Column H: H1 - "no", H2 - "no", H3 - "yes"

- Column I: I1 – 1, I2 – 2, I3 – 3, I4 – 3

Then enter the following array function into C1:

=INDEX($I$2:$I$5, MATCH(A2&B2, $G$2:$G$5&$H$2, $H$5, 0))

Press Ctrl + Shift + Enter for this array function to work and copy this formula down the column. Hope this solution will work for you.

Sir, Please write this formula in C2.

=IF(AND(A2="A",B2="NO"),1,IF(AND (A2="A",B2="YES"),2,IF(AND(A2="B",B2="NO"),3,IF(AND (A2="B",B2="YES"),4,""))))

Help with a formula please:

If A1<=4 and B1 <=2 then C1 is G

If A1 =1 and B1 =3 Then C1 is G

If A1 =5 and B1 =1 Then C1 is A

If A1 =3,4 and B1 =2 Then C1 is A

If A1 =2,3 and B1 =3 Then C1 is A

If A1 =1,2 and B1 =4 Then C1 is A

If A1 =5 and B1 =2 Then C1 is HA

If A1 =4 and B1 =3 Then C1 is HA

If A1 =3 and B1 =4 Then C1 is HA

If A1 =1,2 and B1 =5 Then C1 is HA

If A1 =5 and B1 =3 Then C1 is R

If A1 =4 and B1 =4 Then C1 is R

If A1 =3 and B1 =5 Then C1 is R

Many thanks.

Hello Adrian,

First, write down your conditions in different columns:

– Column G: G1 - 4, G2 - 1, G3 - 5, G4 – 3, etc.

– Column H: H1 - 2, H2 - 3, H3 – 1, etc.

– Column I: I1 - "G", I2 - "G", I3 - "A"

Then paste the array function below in C1:

=IFERROR(INDEX($I$1:$I$17, MATCH(A1&B1, $G$1:$G$17&$H$1:$H$17, 0)), "")

Press Ctrl + Shift + Enter for this array function to work and copy this formula down the column. Hope this is exactly what you need. :)

is something wrong with this formula?

=IF(AND(D3=$A$17, B3=$D$15), $B$17, IF(D3=$A$18, IF(OR(B3=$D$20, G3>$U$18), $B$18,IF(D3=$A$16, IF(AND(MONTH(E3)=$T$18, B3=$D$20), $B$16, $B$19)))))

instead of showing the right output(percentage), it just says "false", the first 3 if work though.

Thanks

please can you help me the formula to this question

Currently, customers are responsible for paying the shipping costs. The sales team suggests that customers really dislike paying shipping costs, and that offering “free shipping” instead of the 1% discount would likely increase sales. Create a formula for the “Sales with Free Shipping” column that subtracts the “Shipping Cost” from the “Sales” only if the “Expanded Order Type” is Extra Large, XX Large, or XXX Large. Copy the formula down to all the rows. What would total 2012 sales have been if the company had offered free shipping instead of the 1% discount.

Order ID Order Date Order Priority Order Quantity Order Type Expanded Order Type Sales Discount Sales with Discount Sales with Free Shipping Ship Mode Shipping Cost

51648 1/1/2012 Low 45 Large XX Large 2354.8 0.01 2331.252 Regular Air 19.99

51648 1/1/2012 Low 50 Large XXX Large 187.88 0.01 186.0012 Regular Air 2.97

29030 1/2/2012 Medium 10 Small Extra Small 192.58 0 192.58 Regular Air 4.1

54214 1/2/2012 Medium 38 Large Extra Large 7325.63 0.01 7252.3737 Express Air 24.49

47591 1/2/2012 Critical 27 Medium Medium-Large 279.4 0 279.4 Regular Air 6.91

43494 1/3/2012 Medium 2 Small Mini 3668.28 0 3668.28 Regular Air 13.99

10945 1/3/2012 Medium 14 Small Small 1170.025 0 1170.025 Regular Air 8.99

35811 1/3/2012 Critical 6 Small Extra Small 10.39 0 10.39 Regular Air 0.7

16164 1/3/2012 Low 26 Medium Medium-Large 2354.15 0 2354.15 Delivery Truck 14

16164 1/3/2012 Low 26 Medium Medium-Large 69.38 0 69.38 Regular Air 4.28

50471 1/3/2012 Low 25 Medium Medium 5859.25 0 5859.25 Delivery Truck 28.16

35811 1/3/2012 Critical 49 Large XXX Large 741.57 0.01 734.1543 Regular Air 1.39

16164 1/3/2012 Low 22 Medium Medium 3353.54 0 3353.54 Regular Air 19.99

31555 1/4/2012 Critical 5 Small Mini 500.5 0 500.5 Delivery Truck 28

55011 1/4/2012 Critical 48 Large XXX Large 452.28 0.01 447.7572 Regular Air 4.82

7107 1/4/2012 Not Specified 3 Small Mini 172.04 0 172.04 Regular Air 11.1

44646 1/4/2012 Low 47 Large XXX Large 12723.95 0.01 12596.7105 Regular Air 35

7107 1/4/2012 Not Specified 3 Small Mini 113.14 0 113.14 Regular Air 5.08

Hello, I need help. I have a range of numbers and looking for If formula which can classify into Over 90 days;

Over 60 days;

Over 42 days;

Below 42 days.

Please, can you help me with it?

IF(AND(B43>0,B4320833,B4333332,B4366667,B43166667,B43666667),(((B43-666667)*0.35)+200833.33))

Hello,

I wish to develop a model in excel that provides information on expected loan repayment from clients on a monthly basis so I can easily match with payments received at the end of the month. If the model can also prompt me on the expected repayments for each date that will be mostly appreciated. It will help me reduce my loan delinquency and default.

Basic chart

Person Product Quantity Person Product Quantity

ABC Orange 200 GHI Banana Formula to get quantity from basic chart

ABC Banana 500

DEF Mango 400

GHI Banana 800

GHI Mango 200

Basic chart Final chat

Person Product Quantiy Person Product Quantiy

A Pen 200 C Rubber Forumula to get quantiy from basic chart

A Rubber 500

B Pen 400

C Pen 800

C Rubber 200

You'll need a few formulas

=SUMIF(B1:B10,"PEN",C1:C10)

Formula above sums the values in C1:C10 for the cells in B1:B10 that has "PEN" in it.

Copy the formula for other products you have.

=SUMIF(B1:B10,"XXXX",C1:C10)**change the XXXX into the product name**

Hi Tried the formula for the time wise but im getting an error for it

=IF(AND(Al2>07:00:00,Al2=08:00:00,A1=09:00:00,A1=10:00:00,Al2<=11:00:00),"10am-11am",0))))

Hello!

Hopefully a simple one.

If (A)-(B)=>0(C) - Ongoing(D)

If (A)-(B)=0(C) - Filled(D)

If (C) is blank - Not Active

Can someone help me with the following logical statement:

IF

"TIMEIN PV"<"TIMEIN DH" AND "TIME IN DH"<"TIMEOUT PV"<"TIMEOUT DH"

OR

"TIMEIN DH"<"TIMEIN PV"<"TIMEOUT DH"

OR

"TIMEIN DH"<"TIMEIN PV""TIMEOUT DH",

ALERT,

0)

The TIMEIN or TIMEOUT (DH or PV) are formatted in 24:00 hours. I want to create an alert when two schedules are clashing like this:

PV (Private) (in)xxxxxxxxx(out) (in)xxxxxxxxxxxx(out) (in)xxxxxxxxx(out)

DH (Dayhab) in ================================================= out

Hello Ash,

Thank you for your comment. As far as I can see, there is a symbol missing in the last part of your formula - "TIMEIN DH"< "TIMEIN PV"”TIMEOUT DH”. Once you add the necessary logical operator (>,<,<>,=) there, it should work. I hope this will help you.

Hi, If 1=500 & 2-700. Want to put this formula.

Can u please help me?

Hi I have 2 questions.

I need to write 2 if arguments

if a2 - ba = >300 then subtract 300, maximum 600 then subtract (a2-b2)-300 answer maximum 300 if not return 0

Question 2

How to embed formulas so excel can be saved and reused without formulas disappearing even if operators mistakenly enter numbers in formula cells

Thank you very much

Hi dear

Can you please let me know how to extract data from a row while comparing multiple sheets' data under some condition in new work sheet?

For example; I want to make a list of top 10 students from multiple sheets and the entire data against these students must be on a single new sheet.

Can you guide please!

Profound regards

=IF(V2=-2,"C","L"),IF(AND,V2>-3,"E")

THIS DOES NOT WORK. NEED TO SHOW C IF 0,-1,-2,L IF GREATER THAN 0 AND E IF -3

=IF(V2>0,"L",IF(AND(V2>=-2,V2<=0),"C",IF(V2<-2,"E","")))

can i get formula for this

• If the industry focus is less than 5 and number of solutions is more than 10 – 100%

• If the industry focus is more than 5 and number of solutions is less than 10 – 80%

• If the industry focus is more than 5 and number of solutions is more than 10 – 60%

• If the industry focus is less than 5 and number of solutions is less than 10 – 40%

• If no data or no information – 20%

Hello

I would like to understand how I can create the following formula within excel;

Column A - Has 3 different values (action 1, action 2, and action 3)

Column B - Arrival Time

Column C - Departure Time

Column D - I need to find the difference in departure time (column C) & arrival time (Column B) of Action 1 (as recorded in column A). However all other times will comeback as 0 (or null figure) as I do not want this to be seen in future analysis

(Column E) - I need to find the difference in departure time (column C) & arrival time (Column B) of Action 2 (as recorded in column A). However all other times will comeback as 0 (or null figure) as I do not want this to be seen in future analysis

(Column F) - I need to find the difference in departure time (column C) & arrival time (Column B) of Action 3 (as recorded in column A). However all other times will comeback as 0 (or null figure) as I do not want this to be seen in future analysis

PLEASE HELP :-)

Identify tickets that do or don't meet the defined service resolution target.

LOW TICKETS Resolved within 336 hours (10 Days)

MEDIUM TICKETS Resolved within 168 hours (5 Days)

HIGH TICKETS Resolved within 4 hours

CRITICAL TICKETS Resolved within 4 hours

=IF ((H2=LOW, F<336, "YES", "NO"))

((H2=MEDIUM, F<168, "YES", "NO"))

((H2=HIGH, F<4, "YES", "NO"))

((H2=CRITICAL, F<4, "YES", "NO"))

I need help in creating one formula that reviews text within cell H2, and then uses the hours the ticket was opened located within F2 and compare it to the given formula based on the ticket priority.

Hi

what is the formula if my condition is

A=1 ,B=2 the output should be c=1.

If A=2,B=3 the output should be c=1

the output should change only if the A= multiples of 1 & B = Multiples of 2 otherwise it will be a least matching.

If there is two dates in a1 and b1

C1 is 0 to 3 months

D1 is 3 to 6 months

E1 is 6 to 12 months

F1 is 0 to 1 year

Please suggest formula

I think I just found heaven!

If there is two dates in a1 and b1

If 0 to 3 months, c1 is yes

If 3 to 6 months, d1 is yes

If 6 to 12 months, e1 is yes

If 0 to 1 year, f1 is yes

Please suggest formula

1. i like to minus Coulmn 1 (1st ship date) to column 2 (2nd ship date) & out come should be in number

2. after that i like to find the max value number in the column.

help me to calcute my commission my commission is .5% but condition is minimum 2 rs and maximum 12 rs

=IF(and(A1>2,A1<12),A1*0.5%,"")

there are so many man or women then how can i find man with help of if formula please let me know

Hi,

I weekly table set up and I want to track if someone does a certain task for consecutive days. What would I use to give 4 points if they did it 4 consecutive days and NOT just for 4 days during that specified time frame? Thank you

Looking for help with: ie. if d43 - 3.75 is <= 0 then equal blank if not then equal d43 - 3.75

=IF(d43-3.75<=0,"",d43-3.75)

Mam kindly give formula to calculate pass or fail for 6 subjects in which marks of 4 subjects is more than 40 and subjects are present in different cell such as a2, e2, j2 , l2, m2 and p2.

Hi,

I want to calculate the sum of the cells if in column B have text "paid" then calculate values from Column A in respective cell and if Column B have text "Un-Paid" then the values from Column A will not calculated... reference list is below...

Rs 3,000.00 Paid

Rs 30.00 Paid

Rs 50.00 Paid

Rs 5,000.00 Paid

Rs 10,000.00 Un-Paid

Rs 10,000.00 Un-Paid

Rs 5,000.00 Un-Paid

Rs 330.00 Un-Paid

Rs 650.00 Paid

Rs 785.00 Un-Paid

Looking forward for prompt response please...

Thanks

If you want something simple you can have another column that determines if column b says paid.

=IF(B1="PAID",A1,0) - this goes in column c

Sum values in column c.

Just realized you can use sumif here

=SUMIF(B1:B10,"PAID",A1:A10)

Change the range as needed.

Hiya,

Trying to create a formula that I can then conditional format based on the result.

Basically:

If >75% of of a column say Yes in a different worksheet, I want it to return a value of Green

If 25-75% of a column say Yes in a different worksheet, I want it to return a value of Amber

If <25% of a column say Yes in a different worksheet, I would like it to return a value of Red

Then I will conditional format these so we can see at a glance how much has been received (I know how to do this so can do this bit).

Thank you in advance for your help.

Trudie

Need to calculate accrual / accumulated leave for current year . Please guide with the “ If condition” :

Sick Leave Prev. Yr Bal. = X

Sick Leave Alloted Current Yr. =Y

Capping for Sick Leave =Z

Below Z to be considered on actual & Above Z will lapse.

Anyone please help.!!!

I need a formular that will either give me

1)Lost Customer

2)New Customer

3)Down-Trders

4)Up_traders

Have tried below but it is not working our

Please help

=IF(D53<1;"Lost Customer";IF(E53D53;"Downtrader";"Uptrader")))

Morning

can you please assist in calculating a if then formula in excel 2016.

I am trying to say if D48+D49>=C40 then D50=E40, if D50 is less than C40 then keep the sum of D48+D49 in cell D50

I'm trying to use a nested IF function using specific ranges of dates but I can't get it to display each answer separately in the same column. For example, I want to display "30 Days" if the condition cell has a date within 30 days out from today, "60 Days" if the date is within 30 and 60 days out, and so on... This is what I have:

=IF(H15-TODAY()>=30,"30 Day",IF(H15-TODAY()>=60,"60 Day",IF(H15-TODAY()>=90,"90 Day",IF(H15-TODAY()>=180,"6 Mo",IF(H15-TODAY()>=270,"9 Mo","12 Mo")))))

Column A is lates

Column B is minutes of lates

If Lates is 1 and minutes is less than 15, Warning

If Lates is 1 and minutes are more than 15, 50%

If Lates are 2, 50%

If Lates are 3 or more, 100%

Tried this formula for the above but it is not working. Can someone please check? Thank you.

=IF(A1=0,0,IF(AND(A1=1, B1=3,1)

HI

QUESTION.. IS THERE AN EASIER WAY THAN: =IFS(AG21=0,"+3",AG21=+1,"+3",AG21=+2,"+3",AG21=+3,"+3",AG21=+4,"+3",AG21=+5,"+3",AG21=+6,"+3",AG21=+7,"+3",AG21=+8,"+3",AG21=+9,"+3",AG21=+10)

THANKS FOR YOUR HELP

IF(A3=70,A3=75,A3=85,A3=95,"C3*2"))

can someone correct this formula for me

what is the formula if one column contains text and we want to copy that in next column and below it until another word appears in the some column within excel?

E.g

1- Next Company Model Management

2- NO TOYS DE

3- Nur Management

Above data needs to be converted into folowing in next coloumn:

Next Company Model Management

Next Company Model Management

Next Company Model Management

Next Company Model Management

Next Company Model Management

Next Company Model Management

NO TOYS DE

NO TOYS DE

NO TOYS DE

Nur Management

Nur Management

Nur Management

Nur Management

Anyone Help For below mention Problem

I have This 3 Same Am mount but percentage is different different,

500 70%

500 80%

500 90%

now what i want i am trying to fix formula in next coalum

Target % Result

500 70% 0 if % below 70 % amount should be 0

500 80% 300 if % between 80 to 85 Result come Automatic 60% From target

500 85% 800 if % between 85 to 90 Result come Automatic 80% From target

500 90% 500 if % Above 90 Result come Automatic 100% From target

Hello-

I am trying to add additional data to an existing If Is formula:

=IF(@O:O<=-3,"25% DISCOUNT - PCS OVER",IF(@P:P<=-3,"25% DISCOUNT - PCS SHORT"," "))

I would like to add the Number (value) of pcs into the formula. The numbers are in columns O (over) and P (short). How would I do this?

I recieve False when I entered this function help pls

If(B3>=10,IF((OR(C3>=10,D3>=10)),"PASSED","FAILED"))

Hi, I have a question if that's okay. I have three adjacent columns with values, lets say for the sake of argument A1,B1&C1, some of which have values in A, some of which have values in C, and all of which have values in B.

A basic formula for my purpose, if there's a value in column A, would be something along the lines of:

=IF(A1"",CONCATENATE(A1,B1,C1))

However, here's where it gets tricky, as I'd only wish it to concatenate A1,B1,C1 if there's also a value in C1. Otherwise I'd like it to return a value of A1. Similarly if there's a value in C1, but not in A1, I'd like it to return a Value of C1.

I've managed in the past to concatenate A1,B1 or return a blank value if there's no value in A1, but what I can't seem to do is return A1 rather than concatenate all three cells if there's no value in C1.

Many thanks for any help anyone can offer in this matter. As a more concrete means of expressing it, let's say that A1 = Dog, B1 = -, C1 = Cat. The result of the formula would be to read Dog - Cat, with or without the space between the hyphens.

However, if A2 = Dog, B2 = -, C2 is blank, the result of the formula would be Dog.

And if A3 is blank, B3 = -, C3 = Cat the result of the formula would be Cat.

Best, Trevor

Sorry, the above should have read adjacent columns A,B,C not A1,B1&C1 and the basic concatenate formula without the additional conditions is actually

=IF(A1"",CONCATENATE(A1,B1,C1))not A1"",CONCATENATE(A1,B1,C1)) as above.

Thanks again, Trevor

Just realised that when posting it seems to be stripping the greater and less than symbols from my formula above which should be immediately after A1. Not sure why but I'll give it another go here just to see if I was really remiss and forgot to include them in my original emails. So far I've tried the formula below, hopefully the greater and less than symbols after A1 will be apparent as I've typed them in this time rather than pasted them, but this returns A1,B1 not just A1. And I haven't even got to the C1 part of the equation yet!

=IF(A1"",CONCATENATE(A1,B1,C1),IF(C1="",A1))

Best, Trevor

Hi all again,

Just to say I resolved it with the following, you have to imagine that it reads =IF(AND(A1lessthangreaterthan"", etc. as it'll probably strip the signs out again.

=IF(AND(A1"",C1""),CONCATENATE(A1,B1,C1),IF(AND(A1="",C1""),C1,A1))

Best, Trevor

Hi,

Hoping to get some help with a formula. Currently I have this formula:

=IF(AND(DL3>=0, DL3=4.1, DL3=4.26), 2, FALSE)))

I also want to add another condition: If 5 or more cells in a range are blank then return "2"

Can this be added to this formula? Or how would you write that?

Here is the range of cells E3:BF3

Hi,

Hoping to get some help with a formula. Currently I have this formula:

=IF(AND(DL3>=0, DL3=4.1, DL3=4.26), 2, FALSE)))

I also want to add another condition: If 5 or more cells in a range are blank then return "2"

Can this be added to this formula? Or how would you write that?

Here is the range of cells E3:BF3

Hi,

Is there any formula for: if the text(Name) comes 2 times in a column take the text to a specific cell if the text(Name) comes 3 times in the column take the text to another cell?

Very very Thanks

Hello

I would like some help with adjusting this formula:

=IF(ISERROR(AVERAGE(G3,K3,N3,Z3,AF3,AO3,AT3,BD3,BF3)),"", IF(DO3<2,AVERAGE(G3,K3,N3,Z3,AF3,AO3,AT3,BD3,BF3), "Invalid"))

I would like the average of the scores above to be calculated based on two conditions.

BOTH DL=1 and DO<2. If both of these conditions are not met then it should read "invalid"

Is this possible? is there another way to write this? (I have included the ISError as I do not want blank cells to produce errors)

I need a formula to do the following;

If "X" is present in A1 - A10 & "Y" is present in B1-B10 (in the same row) what is C1-C10 in the same row.

eg. A2=X & B2=Y what is C2

Can you please help?

I need a formula to do the following:

There is a list of cells in column B. If column B contain text ending with "hba0" or "P0",

Indicate SW1 on column A, next to the row cell in column B. If column B contain text ending with "hba1" or "P1", Indicate SW2 on column A, next to the row cell in column B.

Also to ignore blank or empty cell for the list in column B, thanks.

I need a formula that will return the following:

8 or lower = Pre Contemplation

8-11 = Contemplation

12-14 = Preparation

14 and above = Maintenance

I have a running total cell that will give me the number. Based upon the result of that cell I need it to return the text that corresponds. The below examples shows the column B totaled then averaged. The average equates to 12 therefore based upon the above table should return "Preparation"

Column A. Column B

1 2

2 4

3 6

4 Total 12

5 Preparation

Thank you!

Nevermind...figured it out

My policy is to give Incentive based on year of service of my staffs. For example: I would like to give Rs. 750/- to those staffs who have year of service between 1 & 3 years and Rs. 1,000/- to those staffs having service above 3 years. In addition, if they achieve a Per Vehicle Incentive of > Rs. 500/- only they will be eligible for the above mentioned Incentive. Will u please help me to resolve this?

Hi I am using the following formula =MAX(0,C105-C106)so that I do not get results with a negative answer (e.g. -356). However if cell 106 is blank i would like to have a zero returned. How do I amend the current formula to include this perameter?

Figured it out myself.

=IF(AND(ISNUMBER(C105),ISNUMBER(C106)),MAX(0,C105-C106),"")

Works a treat.

Hi question, using the data below

particulars date received due date date paid action remarks

water 01 jan 2019 31 jan 2019 29 jan 2019 paid w/ deadline

electric 01 jan 2019 31 jan 2019 02 Feb 2019 paid beyond

Dues 01 jan 2019 31 jan 2019 not yet paid

using IF function how to formulate

result if "paid" or "not yet paid"

remarks if "paid" and "within the due date" or "paid but beyond due date"

thank you

Hi There,

I need your advise on the following. I have 3 siblings. Everytime any payment made by either one of our siblings for our parents' affair, we will split the bill. But everytime different sibling will pay the bill first. Therefore, I would like to find a solution which I just need to key in the payment amount and payment by which sibling and it auto calculate each share and who needs to top up their payment and who needs to collect from other siblings. I need to attach a screenshot to show if you can't understand my question.

Hi,

Kindly I need help in this please, I need to count the cells that contain a value x bigger than y and less or equal z.

Many thanks

kindly help me, what is the formula for my below condition

* if i entered in B cell as credit then only C cell will allow to enter the value and D cell

will be Empty.

* if i entered in B cell as debit then only D cell will allow to enter the value and C cell

will be empty.

find a formula for the percentage of the given items.All are in out of 100.

86

98

88

75

92

Exempt

99

73

87

45

Exempt

Hi, I know this is probably something stupid, but so am I lol.

I have data in Cell A and Cell B. If Cell B is greater than 0, then the data in Cell A & B has to be copied to Cell A & B on another sheet?

Hi Riaan,

You can use the following formulas on another sheet:

For cell A: =IF(Sheet1!B1>0, Sheet1!A1)

For cell B: =IF(Sheet1!B1>0, Sheet1!B1)

Where Sheet1 is the sheet with the original data.

I have an actions table where each action has a deadline and a status of whether that action is 'opened' or 'closed'. I am trying to highlight / or colour a row for actions which are still open and have passed the deadline. I tried using combination formulas in conditional formating. But nothing is working for me. Any suggestions?

I am trying to improve my Excel skills. I am stuck on this:

I have a column retrieving data via VLOOKUP. If the result is a blank cell, I would like to have a particular text returned, but if the result is an error, I want a different text. I am guessing this will involve nesting an IF and an IFERROR, but I'm not sure - any help that can be offered is appreciated. Thank you!

Hello,

I am trying to do a formula to highlight cells a certain color based on a name, that are equal to certain calendar days. Could anyone help with this?

I am looking for the same formula. Were you able to figure this one out? Please let me know. Thank you!

Hi - Can you help me solve this formula? Thank you

If Column H >= 100%, then Column N = Column F; if Column G >= 100% and Column H >= 100%, then column N = Column F*2

I want to display Remark in students mark list having following conditions:

Marks >=420 then "Excellent",

Marks Between 360 and 419 then "V. Good",

Marks upto 359 and if pass in all subjects then "Good",

If fails in 1 or 2 subjects then "Average" and

Fails in 3 or more subjects Then "Poor".

All subjects are of 100 marks each. Total 6 subjects and passing marks 35 and above.

How can I display Remark for the above conditions?

I want the formula TAT,

if a2 is <= 5, give me 5, or give me the same cell count,

like its the a2 = 6 then give 6 if its 7 give me 7

Value in a Cell (eg: K2) : 3/13/2019 19:18:26

Condition should be followed as:

Morning (6AM-3PM)

Afternoon (2PM-11PM)

Night (10PM-7AM)

Can anyone help me getting this solved

If >150 A

If <100 C

If 120-150 B

If 100-110 c

I need a formula if 3rd row values can be "solved" then it should return me "0".Else return "1".

Hi.

I am trying and can't find the way of having the following:

I provide a cell and look for in a column that has the name partiallym and need to return the full value of the cell i am looking for on another column, additionally if the value is found on other cells to get all the cells value into a single cell...

I know it is a tricky one :)

Thanks in advance, BTW awesome excel skills!!

Hello! I have been having a hard time trying to figure out how to write a formula to tell me if a football play was successful or not.

Any one know how I would write something that can tell me the following;

On 1st down, we need 40% of necessary yardage to be successful

On 2nd down, we need 70% of necessary yardage to be successful

On 3rd and 4th down, we need 100% of necessary yardage to be successful.

i have been trying but cant figure out a formula for my current need

i have 4 different codes FA or W or D or T each one if code is used has a different amount that is needed to be added

i have this formula but need to add the other letters incase the referenced cell is one of the other codes. i know i'm on the right track but can figure out how to add the other codes in incase the code changes then that nuber in cell O35 will be added to the value associated with the letter for the code

=IF(P35=O70,O35+M70)

HELP !!!

Driving me mad, Im trying to auto add a percentage,

i.e

£0.00 to £10.00 = 50%

£10.00 to £50 = 30%

£100 up = 20%

So B2 is 6.99 and I want E2 to display eather 3.49 or 10.48.

Is this possable? ive tryed in E2

=IF(B2>=10.00, B2+50%, IF(B2>=50.00, B2+30%, IF(B2>=100.00, B2+20%, "")))

Many thanks

hey i have this table

NAMES RANK

ali 30

moses 10

mo 25

eyali 30

and i want to know for example who is the name with the highest rank and his name contain "li" and his rank

in another words, if i have string (like "mo" ) and i want to know who is the name that have highest rank that include this string ( in out example we have "mo" in 2 names, 'moses' with rank 10, and 'mo' with 25, the formula give me the answer 25)

thanks!

when i put no 1 in A1 IT REPRESENT AS ABSENT IN B1

when i put no 2 in A1 IT REPRESENT AS ABSENT IN C1

when i put no 3 in A1 IT REPRESENT AS ABSENT IN D1

when i put no 4 in A1 IT REPRESENT AS ABSENT IN E1

HOW CAN I PUT ABSENT IN ALL FOUR CELLS(B1, C1, D1, E1)AND ANY THREE CELLS USING A FORMULA

I need a formula, which calculate the difference between the maxmum and minimum chainage values provided that the chainage grouped are of the same name which is in column A.

Name of drift (ID) - column A

Chainage from (m)- column B

Chainage to(m) - column C

I need a formula for below

This calculation need to get the incentive for employees. If an Employee Achieve his target than incentive will be 1% as follow

Achievement = 1% of Incentive

95% and above = 100% of 1

90%-94.99% = 85% of 1

80%-89.99% = 75% of 1

70%-79.99% = 50% of 1

60%-69.99% = 30% of 1

Below 60% = 0% of 1

And also one more clause if the collection amount collect on time or as follow :

No of Days = Commission %

01-60 Days = 100%

61-90 Days = 75%

91-120 Days = 50%

121-150 Days = 30%

151-180 Days = Penalty 1%

Above 180 Days = 1.5%

Please help me out for calculation

For Example (Guy Collection 100 Dollar if he achieve and collect on time than will get 1 Dollar) But i want as below

Calculated Amount = 100

Achievement % = 85%

And Collection day = 95 days

Than he will get = Result 0.375 Cent

i having two Excel Files with similar data and need to compare our data in

Excel File - A is having correct information comparing with Excel file B ,

require Your support to find formula to compare EXCEL file A & B

EXCEL file A Column A = 1234 Then 1245 ,1256 and So on in every Column .

EXCEL file B Column A = 1234 Then 1245 ,1256 and So on in every Column .

EXCEL file A Column B and EXCEL file B Column B Having Multiple Bandwidth example (1 MB , 2 MB , 3 MB ,4 mb etc ) ,

how to mention All bandwidth Associated with EXCEL file B Column A = 1234 WITH in EXCEL file A Column C

Please give the formula for the below condition.

REFUND AMOUNT UPTO RS.25L-OUR CHARGES 5% WITH MIN RS.5000/- WHICH EVER IS HIGHER

Hi,

I cannot get my function to work even following all the examples above. My scenario

B3=Amount that can change

Where the amount is under $50000, cell will equal B6*B16

Where the amount is equal or over $50000, cell will equal B6*B17

TIA

Hello! I have been having a hard time trying to figure out how to write a formula which tell assume that the produce will harvest on 3/20/2020 so irrigation is applicable each month to grow. However; irrigation is not applicable between 3/19/2020 and 3/20/2020.So any help is much appreciated .

For fertigation no problem i use this

=IF(AND($C$9E2,$B$9=0.2),0.8,"-"))

where C9= Harvest date

E2= Application date

B9= Area

from this when C9=E2 no fertigation the same is true for irrigation the difference is one day less than the harvest date.

correction

=IF(AND($C$9E2,$B$9=0.2),0.8

Need a formula that says...

If cell A1 is has the text "Oshkosh","NEW Oshkosh", or "Shumaker", put 36,500 for the text Oshkosh, 37,500 for NEW Oshkosh, or 37,500 for Shumaker.

Can you help me.

Hi Bob,

I believe this is the formula you are looking for:

=IF(A1="Oshkosh", 36500, IF(A1="NEW Oshkosh", 37500, IF(A1="Shumaker", 37500, "")))

Thank you. That is actually what I needed. Just couldn't wrap my head around it.

=IF((LEFT(F10,2))=29,"-",G10*18%)

I want a formula for comparing end date to decide the application.

if start date = end date,replay 0

if start date = 1-end date,replay 0 or else 1

I am trying to create a formula using criteria in the same column which could be either a number or a word. Example 7230 or "Store". I want the formula to return the word "Direct" if the answer is true or "Overhead" if the answer is false. Hope you can help

may I know the excel formula if value below 10 and I need to plus 2.

eg. =<10+2

Hi,

I'm trying to make the logic

if A1=B1 then true; A1=C1 then true; A1 not=B1 & C1 then False.... nested functions OR functions nt working. kindly advice.

Regards

date 1 2 3 4 5 6

name total bonus normal

james 300 360 400 370 403 360 2193 393 1800

ken 340 350 334 342 401 359 2126 326 1800

geff 350 370 336 420 389 349 2214 414 1800

brian 300 390 337 436 376 57 1896 96 1800

robert 400 340 361 340 369 367 2177 377 1800

peter 365 366 352 345 346 301 2075 275 1800

nicholus 333 358 369 368 352 300 2080 280

judith 420 309 345 369 323 326 2092 292 1800

muati 440 470 321 370 310 326 2237 437 1800

19090 2890 16200

i need a formula to calculate the sum of any amount in excess of 300 from day 1 to day 6

e.g day 1 (x-300)+day 2(y-300) till the sixth day.remember the sum should not be affected by a negative value i.e if x is less than 300

=IF(AND(E6="FP",M6>=2,AND(A6>=$K$1,B6=2),AND(A6>=$K$1,B6<=$L$1)),"VD Promo","No Promo")

please help me to run the statement

=IF(AND(E6="FP",M6>=2,AND(A6>=$K$1,B6<=$L$1)),"VD","No Promo")

This is the correct one please help me to run the statement.

Hi there - this article is very helpful but I am struggling to create a formula to calculate a cost-price based on various criteria but not sure if these comments are being monitored still and if so should I upload an excerpt from my spreadsheet to show what I am trying to achieve?

Dear sir/mam

If sales value is =10 lakh then % incentive will be 4%.how we solve this with the help of nested if function

This is the formula I am trying to calculate - here are the criteria https://i.imgur.com/S3u7NJC.png

1 - this is the cell where I need the formula to calculate my cost price.

2 = "Paid" or "Traded" and

3 = the Transaction Type is "Transfer" then

4 - take the value from the cell in column "Adj EUR to AUD Rate" and divide it by

5 - (on the same row as he cell to calculate the cost price)

However only take the value in "4" if on the same row as "4"

6 = FX Transfer

7 = Xfer_Receipted

8 = the date matches the date in the same column as the row of the cell for "1" (the cost rate we are calculating" and

9 does not equal "0"

I hope that makes sense and appreciate any help

@Svetlana Cheusheva are you able to help with my query please?

Is it possible to write a formula for a whole column?

IE, Currently column 'C' divides 'D' but i need a formula that If C>D divide D by C.

Hi Gary,

Usually, you write a formula for the first cell using relative references (without $ sign), and then drag it down to as many cells as needed. This will copy the formula across the column and adjust the references for each row. For example, if your data begins in row 2, enter this formula in any cell in that row:

=IF(C2>D2, D2/C2, "")

And then, double-click the fill handle (a small square at the lower right-hand corner of the cell) or drag it over the cells where you want to copy the formula.

For more information, please see How to copy formula in Excel.