Comments on: Excel IF statement with multiple conditions

For powerful data analysis, you may often need to build an Excel IF statement with multiple conditions or use IF together with other functions. This tutorial will show you the most effective ways to do this. Continue reading

Comments page 43. Total comments: 4573

  1. How to i make a list of words in a drop down box in excel equal a number 1 or 0 when selected.

    1. Hello!
      I’m sorry but your task is not entirely clear to me. For me to be able to help you better, please describe your task in more detail. Give an example of the source data and the expected result.
      It’ll help me understand it better and find a solution for you. Thank you.

  2. Please help in vote results to ascertain Candidate(s) who only WON, TIED in top results in cell G2:G106 "Who Won" in polling stations B2:B106 in colum B2 for
    Two or more candidates results example Abraham Colum C2=40, Bryan Colum D2=70, Charles Colum E2=102 Denis Colum F2=102

    1. Hello!
      I’m sorry but your task is not entirely clear to me. For me to be able to help you better, please describe your task in more detail. Please specify what you were trying to find. What do you want to write in columns B and G? Give an example of the expected result.
      It’ll help me understand it better and find a solution for you. Thank you.

  3. Hello! I need help with an IF formula:

    If column A is CAD, return value from column F
    If column A is USD, return value from column F & G with a space between the two values. Column F will always be text and G will be numbers.

    Thanks!

    1. Hello!
      If I got you right, the formula below will help you with your task:

      =IF(A1="CAD",F1,IF(A1="USD",F1&" "&G1,""))

      or

      =IF(A1="CAD",F1,IF(A1="USD",CONCATENATE(F1," ",G1),""))

      or

      =IFERROR(IFS(A1="CAD",F1,A1="USD",CONCATENATE(F1," ",G1)),"") (Office2019, Office365)

      I hope it’ll be helpful.

      1. Thank you sooo much this worked perfectly!!

  4. Hi, I am new to excel formulas. Can you help me with this
    if a date listed in a column of another page equals the same date of the current page, then a specific column/row total from the other page equals total on current page designated column/row.
    thanks

    1. hmm, guess I don't even get a reply...? thanks

      1. Hello!
        Your description of the problem is not very clear. However, a formula like this may be suitable for you.

        =IF(A1=Sheet1!A1,SUM(Sheet1!B:B),0)

        If this is not what you wanted, please describe your problem in more detail.

  5. I have days in one column line 1, 2, 5, 6, 1, 2, 6 5,3,2,0,4,6,7,4,1,3,2
    I need the result like if the days are between 1 to 3, then the next column should update as 1 to 3 Days.

    1 next to that cell should show 1 to 3 Days
    2 next to that cell should show 1 to 3 Days
    3 next to that cell should show 1 to 3 Days
    4 next to that cell should show 4 to 6 Days

    1. Hello!
      If I understand your task correctly, the following formula should work for you:

      =IF(A1<4,"1 to 3 Days",IF(A1<6,"4 to 6 Days","7 Days" ))

      I hope this will help

    2. Hi,
      had to try. I have a suggestion for this. It is not pretty, someone for sure will find more elegant solution, but it should work.

      For me in this forum the larger than and smaller than symbols doesn't seem to show at all so I'll use capital L for larger than symbol and capital S for smaller than symbol. Let's assume that the list of days is located to A-column and it starts from line 2. I wrote this formula on cell B2.

      =If(A2L6, "error, too high date", IF(A2L=, "4 to 6 Days", IF(A2=0, "error too low", IF(A2S=3, "1 to 3 Days", "unknown error")

      Hopefully this helps :)
      Antti

  6. Hi,
    I think this answer should be exctremely easy, but I just cant find the correct answer.

    I have column with differend numbers (1-18 representing differend areas and I have named the column "Area") and I like to use the Area column to let my formula count all the data from that spesific line. Formula looks something like this:

    =AVERAGEIFS(E3:E1500, E3:E1500,"0", Area, 1)
    (there might be errors in my typing, because Finnish version has a bit differend style to write the formula).

    I would just like to be able to choose with the same time with the same formula multiple area numbers. Like:
    =AVERAGEIFS(E3:E1500, E3:E1500,"0", Area, 1 or 3 or 8)

    Thank you for your help.

    1. I don't know why it removed my typing for with the 0. The formula checking that the counted number is differend than 0 (with Finnish Excel it is " 0")

      1. Ok, larger than and smaller than wont show up :)

  7. Hello - I need some help with IF/AND functions or maybe it is another formula entirely. I have two columns of data with numbers separating subsets. I am trying to assign the number value to each subset. So there could be 10 data points in one subset, and 20 in another but I want the same identifier for all of the datasets in that subset. This formula simply found that what I'm looking for is a number, but how do I return the value of that number? =IF(ISTEXT(B4),"Text",IF(ISNUMBER(B4),"Number",IF(ISBLANK(B1),"Blank",""))) Thank you!

  8. hey everyone, need help with a formula with a different outcome for 4 different Conditions;
    IF A1=R output should be 25
    IF A1=RR output should be 37.5
    IF A1=G output Should be 50
    IF A1=GG output Should be 93
    please anyone???

    1. Hi,
      Try this.
      =IF(A1="R", 25, IF(A1="RR", 37.5, IF(A1="G, 50, IF(A1="GG", 93, "Wrong input"))))
      Sincerely,
      Antti

  9. Hi!
    I need to highlight 20 columns, if 3 of the columns have yes then its good if not I need it flagged. How can I accomplish this?

  10. Hi, I have a pretty complex (for me) formula that i want to write.
    If a<b, then a*c
    If d e, AND if f="x", then a*g; BUT if f="y", then a*h; BUT if f="z", then a*i
    If j k, AND if f="x", then a*l; BUT if f="y", then a*m; BUT if f="z", then a*n
    If o p, AND if f="x", then a*q; BUT if f="y", then a*r; BUT if f="z", then a*s
    If a>p, AND if f="x", then a*t; BUT if f="y", then a*u; BUT if f="z", then a*v
    Can anyone please suggest a way how I can do this.

  11. Hi, I am using the IF with AND & OR functions. Within that though, I have a cell with a flavour name, which I want to assign a number. How do I do that, please?

    1. Basically, I want to say "(C3)banana + (D3)1.0 = (E3)$40" or "(C3)banana + (D3)2.0 = (E3)$75"
      C3 being the flavour and D3 being the weight, while E3 has the function which gives the price for the stated flavour and weight.

  12. I am trying to work an amortization schedule that will be calculated base on Purchase date-Sale Date-Floor plan-Non Floor Plan Date and availability date.
    Column G Column H Column K Column M
    Date of Purchase Date of Sale Floor plan due date Loan End date
    Jun-17 Jun-20 Dec-19 Jul-20
    Jun-17 Available None May-22
    Jun-17 June-20 None May-22
    This is what i have so far and it is working great.
    =IFS($K$99=$H$99,0,P1>$M$99,0,P1=$K$99,$O$99,P1$H99,0,P1>$K$99,O100-P32,$K$99=$H$99,0,TRUE,0)
    But as soon as my Floor Plan end date has None, the formula doesn't work any more. I need to add a this condition to my formula IF(AND(AND(Month=G1,K1="None",h1="available",Loan amount,0)
    Any suggestions?

  13. Hello.
    I have a spreadsheet that is giving me an issue.
    This what I have and its returning the correct response except for 128:Up with 132: Down
    and it returns "FALSE" if AV5 is blank.
    =IF(AW$5>0,IF(AW132="Down",IF(AW128="Down","Yes",IF(AW128="Up",IF(AW132="Up","Yes","No"))),"Yes"))

    What I want it to do in cell AV134:
    If AV5 is blank then I want AV134 to also be blank.
    IF AV132 AV128 AV134
    Down Down Yes
    Down Up No
    Up Down No
    Up Up Yes
    Thank you for any clarification that you are able to provide.

  14. I need to write formula where if column A equals multiple value (e.g. 1, 2, 5 & 6) and column B is more than 7, then "Y" if not "N".
    I wrote the formula as "IF(AND(OR(A=1, A=2, A=5, A=6), (B>7), "Y", "N")
    i think it's wrong since there's no "Y" value at all.
    Thanks!

  15. D S.I 0-35 36-45 46-60 70+
    300000 300000 1778 2576 3651 6642
    300000 500000 2446 3451 4646 8283
    500000 500000 1523 1936 2480 4127
    500000 700000 1790 2240 2888 5167
    600000 600000 1398 1707 2310 4127
    600000 800000 1650 1993 2643 5006
    800000 800000 1387 1570 2230 4641
    800000 1000000 1655 1859 2576 5397
    1000000 1000000 1409 1560 2089 4641
    1000000 1500000 2052 2272 2982 6073
    1500000 1000000 1325 1449 1955 3471
    1500000 1500000 1968 2160 2848 4641
    1800000 1000000 1306 1437 1967 3029
    1800000 1200000 1563 1722 2325 3471
    2000000 1000000 1294 1432 1979 2795
    2000000 2000000 2506 2785 3682 4899
    2000000 3000000 3652 4076 5310 6936

    how to use if formula when i enter age, deductible and sum insured and automatically premium generated

  16. What kind of formula I need to obtain expiration date on courses that have different length of expiration i.e some expire in 7 days, some in 14 and others in 21 days. I only have their start date.

  17. Hello everyone,
    I hope you are well.
    I have a question, if somebody can help me out, I am struggling long time already.

    i have numbers from 0 to 360°. When i enter any numbers from 0 to 360, it should gave me the final answer as per below table. I did a formula that works but only for few numbers not all (=IF(AND(0H10), "0.5", "0")), so if am choosing numbers from 0 to 44, i have the answer 0.5 and more than 45 is answer 0,
    but now i came to a problem how to insert multiple IF and AND in one long formula. I tried but always something wrong.
    I would like to have in the empty cell with formula that is choosing automatically from the main table as per the insert number from 0 to 360°.

    N 000 0.5
    015 0.5
    030 0.5
    NE 045 0
    060 0
    075 0
    E 090 -1
    105 -1
    120 -1
    SE 135 -1.5
    150 -1.5
    165 -1.5
    S 180 0
    195 0
    210 0
    SW 225 -0.5
    240 -0.5
    255 -0.5
    W 270 0.5
    285 0.5
    300 0.5
    NW 315 0
    330 0
    345 0

    Thank you very much guys, much much appreciated. Have a great day all !!

  18. I have a list of mileage date captured over a month with numerous entries each day I need to extract the max and min mileage per day.
    please help with a formula

  19. I need help on a timecard formula. I'm brain-dead right now. If A + B + C > =40, "40" otherwise it should be the sum of A + B + C only. How do I do the "Otherwise" portion of this formula is the sum is less than forty hours?

  20. Hi, I am hoping there is a way to do this. It seems basic, but I am new to these Excel IF statements. I have two columns (F & G) that I need to have high, medium and low values in. And then I want to have a priority level column where I assign a priority level of either high, medium or low based off of the combination of the entries in columns F & G.
    Here is my scoring logic below. Wondering if this can be put into an IF statement and how to enter it?

    If 1 value is high and the other is high then the result is high
    If 1 value is high and the other is medium then the result is high
    If 1 value is high and the other is low then the result is medium
    If 1 value is medium and the other is medium then the result is medium
    If 1 value is medium and the other is low then the result is medium
    If 1 value is low and the other is low then the result is low

  21. Please send me correct formula

    BELOW 1 THEN 0
    FROM 1 TO 250000 THEN ACTUAL FIGURE
    FROM 250000 ABOVE THEN 250000

    1. Hi,
      Again, I don't know why, but for me this message board wont show my larger (L) than and smaller (S) than symbols. I will use capital L and capital S for them.

      Let's say that your number is on A column and starting from A1.

      =IF(A1 L= 250000, 250000, IF(A1 S 1, 0, A1))

      Hopefully this helps.
      Sincerely,
      Antti

  22. This is scenario I am struggling to create a multiple formula:
    1.If AA2 = Y and AB2 = Y results should be "Accrue income"
    2 If AA2 = N and AB2 = N results should be "not Accrue Income" and
    3. If AA2 = Y and AB2 = N results should be " Not Accrue Income and vice versa.
    Thank you for your help

    1. Hello!
      If I understand your task correctly, the following formula should work for you:

      =IF(AND(A2="Y",B2="Y"),"Accrue income",IF(AND(A2="N",B2="not Accrue income"),"N",IF(AND(A2="Y",B2="N"),"Not Accrue income and")))

      I hope my advice will help you solve your task.

      1. Hello.
        I have a spreadsheet that is giving me an issue.
        This what I have and its returning the correct response except for 128:Up with 132: Down
        and it returns "FALSE" if AV5 is blank.
        =IF(AW$5>0,IF(AW132="Down",IF(AW128="Down","Yes",IF(AW128="Up",IF(AW132="Up","Yes","No"))),"Yes"))

        What I want it to do in cell AV134:
        If AV5 is blank then I want AV134 to also be blank.
        IF AV132 AV128 AV134
        Down Down Yes
        Down Up No
        Up Down No
        Up Up Yes
        Thank you for any clarification that you are able to provide.

  23. Hi, Im trying to calculate the following,
    Rep 1 belongs to team 1
    Rep 2 belongs to team 2
    Rep 1 has an individual Count
    Team 1 has an average rate
    for Example:
    If rep 1 Count >=2 or the average rate for Team 1 >=3% then rep 1 will get 5 points, if the cell is blank then zero, if none of these is met then -2 points and same for team 2. this is what i have so far but is giving me an error on the formula:
    =IF(AND(C8="Team 1",$C$30>=3%),5,IF(AND(C8="Team 2",$C$29>=3%),5, IF(D8>=2),5, IF(OR(D8="-",d8=””)0, -2))))
    Hope this is clear, thank you in advance

    1. Hello!
      I’m sorry but your task is not entirely clear to me. Could you please describe it in more detail?
      What does "If rep 1 Count >=2"? Write an example of the source data and the result you want to get.
      It’ll help me understand it better and find a solution for you. Thank you.

    2. Nevermind, i was able to figure it out, =IF(OR(AND(C9="Team1",$C$30>=3%),(D9>=2)),5,IF(OR(AND(C9="Team2",$C$29>=3%)),5,-2))
      Thanks anyways, you're examples really helped me.

      1. =IF(D8="",0,IF(OR(AND(C8="Villains",$C$30>=3%),(D8>=2)),5,IF(OR(AND(C8="Heroes",$C$29>=3%)),5,-2)))

  24. My query is that in marksheet or data sheet some cell are empty and i want that i only write student name and blank cell with subject show automatically.

  25. I'm not sure if this has already been asked before but I am looking for a formula with both And and OR I believe that is looking at 3 different cells to have 4 different outcomes. with numbers between a certain figure
    if a1,b1,c1 is less than 5 and less than 240 then it is letter if a1,b1,c1 is less than 26 and less than 353 it is Large letter and then if it a1,b1,c1 is less than 160 and less than 450 it is Packet? if over 160 and 450 then box.
    Thank you for your time.

    1. Hello!
      I’m sorry but your task is not entirely clear to me. Could you please describe it in more detail? What result do you want to get? Thank you!

      1. I would like 1 formula to display whether entering 3 dimensions (a1,b1,c1=25,150,350) if 1 of the cells is less than 5 and another is less than 240 it brings back "Letter" if 1 of the cells is less than 26 and another is less than 353 then it brings back "Large letter" if 1 of the cells is less than 160 and another is less 450 then it brings back "Packet" and if it has 1 cell over 450 then it is "box".

  26. If an excel sheet acetic acid 15kg, another sheet acitic acid, how i correct spell automatically acetic acid for collect information through vlook up formula from a sheet where 15 kg have.this type of problems i face continuously when i work big data. Pls give me solution

    1. Hello!
      I’m sorry but your task is not entirely clear to me. For me to be able to help you better, please describe your task in more detail. Please specify what you were trying to find, what formula you used and what problem or error occurred. Give an example of the source data and the expected result.
      It’ll help me understand it better and find a solution for you. Thank you.

  27. Hello, this site has some great tutorials, but I'm stuck with a problem I can't find a solution to. Hoping you can assist. I have a table showing values month over month, like this:
    A1=project number
    B1=Project name
    C1=October budget
    D1=November budget
    E1=December budget
    What I would like to do is verify the values month over month and if it is the same it replace the value with $0, if it is more than the previous month, it shows the difference, if it is blank it shows the previous month as a negative loss, if it is less, it shows the difference as a negative. A bit convoluted but I feel the solution is just out of my reach!
    L.

    1. Hello!
      I’m sorry but your task is not entirely clear to me. Could you please describe it in more detail?
      Write an example of the source data and the result you want to get.
      It’ll help me understand it better and find a solution for you. Thank you.

  28. I want if b2=1,20% (1+1)*10
    if b2=2,50% (2+1+2)*10
    if b2=3,90% (3+1+3+2)*10 continue to n number how to possible?

    1. Hello!
      I’m sorry but your task is not entirely clear to me. For me to be able to help you better, please describe your task in more detail. Give an example of the source data and the expected result.
      It’ll help me understand it better and find a solution for you. Thank you.

  29. N4=IF(G4=1,"H4+I4-L4",IF(G4=2,"H4+I4",IF(G4=3,"H4")))

    Incase of G4=1 Output come, H4+I4-L4 instead of numerical value
    Incase of G4=2 Output come, H4+I4 instead of numerical value
    ...........
    Is there any problem with my if formula? why i dont get numerical value on N Column?

  30. Good Morning! im trying to write a formula that looks at a frequency eg. 6 months, 1 year, 2 year, 5 years and if its X add that number to date inserted in a seperate column. so A would be 1 year, B would be "test date" and C "Due Date" currently have the below, but isn't working.
    =IF(OR(E17="1 Year",EDATE(L17,12)),IF(E17="2 Years",EDATE(L17,24)),IF(E17="5 Years",EDATE(L17,60)))
    Thanks in advance.

    1. Hello!
      If I understand your task correctly, the following formula should work for you:

      =IF(E17="1 Year",EDATE(L17,12),IF(E17="2 Years", EDATE(L17,24),IF(E17="5 Years",EDATE(L17,60))))

      I hope this will help

  31. Hello, greetings for the day, my problem is i want to write a formula a1 has 350000 and a2 has 13000 and in the cell a3 i want to write like this if a1 < 500000 and also a2 greater than 12500 then a3 should be a2-12500. how can i do this? and if a1 400000 and a2 11000 and a3 should be a2 cause it is less than 12500. to the point if a2 is greater 12500 then it(a3) should be after deducting 12500 and if it(a2) is less than 12500 it can be that amount but primary condition is a1 must not have more than 500000. answer to this question is highly appreciated. Thank you in advance.

  32. I need to apply formula for Cell A1, to find its 70% or 10000 whichever is less

  33. Hi Alex! Hope all is well and that you could assist me with my Index formula as it's currently not working. I'm trying to use the index formula where it matches the keyword & returns the category. Unfortunately it's not working and hoping that you could assist.

    Data
    Post Date Check Description Debit Credit
    07/24/2020 SHINE MEDICAL 21022.00
    07/24/2020 TA INSTRUMENTS-W DIR-DEPT 7200.00
    07/24/2020 ORBITAL SCIENCES EFT 25594.00
    07/24/2020 THE BOEING CO BCAGPAYSVC 16480.00
    Formula
    Balance
    {=INDEX(K2:K15,MATCH(TRUE,ISNUMBER(SEARCH(J2:J15,C2)),0))}

    Keyword
    SHINE MEDICAL
    TA INSTRUMENTS-W DIR-DEPT
    ORBITAL SCIENCES EFT
    THE BOEING CO BCAGPAYSVC
    UNEX DISB
    CHECK NUMBER

    Categories
    WIRE
    WIRE
    WIRE
    WIRE
    WIRE
    CHECKS PAID

  34. hello, i would need a bit of a help with formula.
    in sheet1 in column A i have names, they are starting from row 3. in row 2 starting from column B i have numbers from 1 to 31.
    numbers represent dates. so i am filling that table with "1" when someone is there and i leave cell empty when that person was not working that day.

    now hard part.
    sheet 2
    there i need some formula here i will be able to pick number/date and that formula to show me who was working on that day. then to print them, and to pick another date/number.

    thanks

    1. for first 2 dates i have done something like this
      =IF(D2=1,IF(Sheet1!D4=1,Sheet1!C4,""),IF(D2=2,IF(Sheet1!E4=1,Sheet1!C4,""),""))
      do i have to do same for all 31 dates or is there something easier?

  35. Hello! I cannot figure out the formula to "FLAG" a row for if each of the following conditions is not met:
    - If e2= "TRUE", then c2="TRUE" and d2="TRUE"
    - If d2= "TRUE", then c2="TRUE"
    - If c2= "FALSE", then d2="FALSE" and "e2="FALSE"
    - If c2= "TRUE"and either f2 OR g2="TRUE", then d2="TRUE"

    Please let me know if you can help! Thank you

    1. Hello!
      Please describe your problem in more detail. It’ll help me understand it better and find a solution for you. Thank you.

  36. Hi, I have a table of data & want a formula to find all the orders which have both a basin and a PEP :
    IN052816 FRT FRT
    IN052816 BASIN VBAML55MSMNO
    IN052816 PKG PEP
    IN052817 FRT FRT
    IN052817 BASIN VB-BAR-48-NO
    IN052817 PKG PEP
    IN052817 ACC NONSTOCK
    I have tried pulling all the basins to a separate tab & using the following formula: =IF((AND(K:K=PEP!K:K,PEP!M:M="PEP")), "Pass", "Fail") (K is IN (1st) column, M is PEP (3rd) column) but all it comes up with is FAIL
    Please help!

    1. Hello Sally!
      I’m sorry but your task is not entirely clear to me. Could you please describe it in more detail?
      Is your data recorded in one cell or in several?
      There is not a single value in the sample data to find BOTH basin AND PEP. Each of the lines contains OR the first, OR the second.

      1. Hi Alexander, thank you for getting back to me.
        The original data is in one tab A-AF 1-29808, with each item on its own line & column (sorry the post above doesn't look like it).
        I appreciate the Basin & the PEP are on separate lines, I thought I could use the invoice number to determine the number of times they appear together as one invoice number would appear multiple times relating to each item on the invoice (K). I couldn't think of a way from this to find how many times a PEP (M) was on the same invoice as a Basin, so I copied all the Basins (L) onto one tab, and the PEP's onto another tab and tried the formula above on the basin tab, looking to the PEP tab to find a match.
        Column K = Invoice Number
        Column L = Category - Basin
        Column M = Item - PEP
        Does that help you understand what I am trying to do? and what data I am working with?
        Thanks
        Sally

        1. Hello Sally!
          If I understand your task correctly, the following formula should work for you:

          =IFERROR(INDEX(K1:K20, SMALL(IF("BASINPEP"=L1:L20&$M$1:$M$20,ROW(K1:K20)-0), ROW(INDIRECT("1:"&ROWS(K1:K20))))),"")

          This is an array formula and it needs to be entered via Ctrl + Shift + Enter, not just Enter.
          If your table has header rows, replace 0 in the formula with the number of those rows.

  37. I am trying to create a formula for my spreadsheet for multiple ITEM in a single cell
    If there is a "29" in a cell, then formula will D1+E1,
    If there is a "31" in a cell, then formula will D1
    If there is a "32" in a cell, then formula will D1+E1-F1
    ...........

    Here 29,31,32 ... etc area type fabricated rebar size in civil construction.
    so i use following formla
    =IF(H1=29,"D1+E1",IF(H1=31,"D1",IF(H1=32,"D1+E1-F1")))
    For 29 answer shows "D1+E1" instead of (D1=5+E1=7)=12

    Please help!

    1. Hi,
      The reason it is showing D1+E1 is because you put it quotation marks.
      just put D1+E1.

    2. Hello!
      You named the condition "If there is a“ 29 ”in a cell, then formula will D1 + E1". This condition is written in your formula.
      Why do you expect "(D1 = 5 + E1 = 7) = 12" to be executed (I don't really understand what this expression means)?

      1. Hello, Can you help me solve this?

        I need a formula in cell C5 that does the following:
        IF A1+B1 4 but 9 but 15, return $75
        Thanks!

        1. Hello!
          Sorry, it's not quite clear what you are trying to achieve. Could you please describe it in more detail? What result do you want to get? Give an example of the source data and the expected result.

  38. Hi! I need to convert the following from Google Sheets to work in Excel
    =ifs(N9=1,I9/10,N9=2,I9/100,N9=3,I9/1000,N9>3,I9/10000)

  39. Hi,
    Hope you are doing well.
    I wanted to know what is the formula used to derive how many sequences a person has carried out each day. Below is my example..Everyday the person will enter his/her start no. and end of the day the closing no. and i needs to check how many sequences each person has done.

    Thread Tester Seq Started Seq Completed Total Seq.Executed
    MOT-FST-83 MEETA 1 5 5
    MOT-ITM-146 AK-2 0 0 0
    MOT-ITM-147 LD-4 5 5 1
    MOT-ITM-148 LD-3 1 1 1
    MOT-MSA-17 LD-1 33 36 4
    MOT-MSA-18 AK-1 35 36 2
    MOT-MSA-20 AS-2 4 6 3
    MOT-MSA-21 MB-3 6 6 1

    1. Hello Linda!
      To calculate the amount for each person, use the SUMIF function. Use the person's name as a criterion for counting. Read the detailed instructions in this article.
      I hope this will help, otherwise please do not hesitate to contact me anytime.

  40. Hi,
    My Name is Pradeep ,I need help for example state and brand wise subscriber count data in a sheet .so my requirement is .
    1st Condition ---
    If I select only state one name then subscriber total count show only selected state sum of count .
    2nd Condition ---
    If state and town then subscriber total count show only selected state and town sum of count.
    3rd Condition ---
    If state and town any name both are no select then subscriber total sum of count show.
    Date for your reference ---
    State Brand Total
    Ayodhya IDEA 188
    Ayodhya Voda 4189
    Gorakhpur IDEA 541
    Gorakhpur Voda 3994
    Kanpur IDEA 2072
    Kanpur Voda 8248
    Lucknow IDEA 1739
    Lucknow Voda 21211
    Prayagraj IDEA 723
    Prayagraj Voda 5028
    Varanasi IDEA 898
    Varanasi Voda 5496
    I am waiting your reply ..

    Thanks
    Pradeep

  41. Hello,

    I'm trying to determing which shipping containers were unloaded within the expected allocated time based on the number of pieces in the container. I have the total time it took to unload the containers in question and the amount of pcs on the containers. What formula can I use to determine if the container was unloaded within the threshold set based of the container pieces?

    Hoping someone can help me!

    < or = 399 pieces = 60 - 120 min per container
    400 - 899 pieces = 120 - 180 min per container
    900 - 1100 pieces = 180 - 240 min per container

    1. Hello Alex!
      Please try the following formula:

      =IF(A1<=399,IF(B1*60*24<=120,"Yes","No"), IF(A1<=899,IF(B1*60*24<=180,"Yes","No"), IF(A1<=1100,IF(B1*60*24<=240,"Yes","No"),"")))

      Cell B1 contains the execution time of the operation in the time format "hh:mm:ss"
      Hope this is what you need.

  42. Hello
    I'm looking for a way to create a formula or macro that will check the value or entry in a column then have it enter the results based on the formula/macro in 2 different columns.
    Example
    Column A Column B Column C
    12345 212456 230456
    12366 217456 (null or blank)

    For the above the criteria it would be IF column A = 12345 then column B = 21256 and column C = 230456
    The data in column A is large with over 300 possible numbers.

    1. Hello James!
      The information presented to you is not enough to give you advice.
      You didn't say anything about the verification criteria. But an Excel formula can only enter a value in one cell.

  43. Hello Alexander!
    I wonder if you can help me?
    I have a nested IF formula which works fine;
    =IFERROR(IF(Homepage!$L$4="Asda",'CPA - Hotspots Asda'!B12,IF(Homepage!$L$4="Tesco",'CPA - Hotspots Tesco'!B12,IF(Homepage!$L$4="Boots",'CPA - Hotspots Boots'!B12,IF(Homepage!$L$4="Field",'CPA - Hotspots Field'!B12,IF(Homepage!$L$4="Ireland",'CPA - Hotspots Ireland'!B12,IF(Homepage!$L$4="Morrisons",'CPA - Hotspots Morrisons'!B12,IF(Homepage!$L$4="Sainsburys",'CPA - Hotspots Sainsburys'!B12,IF(Homepage!$L$4="Sainsburys Trial",'CPA - Hotspots Sainsburys Trial'!B12,IF(Homepage!$L$4="Savers",'CPA - Hotspots Savers'!B12,IF(Homepage!$L$4="Superdrug",'CPA - Hotspots Superdrug'!B12,IF(Homepage!$L$4="Wilko",'CPA - Hotspots Wilko'!B12))))))))))),"")

    I now however need to add another element to this whereby even if L4 on the homepage states "Asda", if B28 states "No", I need it to direct to a different sheet, but if it states "Yes" it continues to pull from B12 on the 'CPA - Hotspots - Asda' sheet, and then I also need this to continue for each individual If statement. Is this possible at all? Thanks

    1. Hello Leena!
      It is very difficult to understand a formula that contains unique references to your workbook worksheets. For the same reason, I cannot check her work.
      If I understand your task correctly, you can change the formula

      =IF(AND(Homepage!$L$4=”Asda”, B28="Yes"), [your formula], IF(AND(Homepage!$L$4=”Asda”, B28="No"),[direct to a different sheet],""))

      I hope it’ll be helpful.

  44. Hello,
    I have a medical insurance cost comparison. Using data from multiple insurance quotations, with a number of factors to consider (Age, Gender, Salary and insurance Category), what formula would I have to use to return the cost in a specific cell (costing data found on a secondary worksheet, within the same workbook)? For example, Employee A is 30 years old, Single Male earning $4,070 per month and is entitled to Category B Insurance the cost from Insurer 1 = $6,696 per annum

  45. can anyone please help me with this.
    assume i have different data in A1 like 12ABCD999 OR 45JKLM888 OR 78MNOP111 and many more. now i want if value of first 2 number of A1 starts with 12 then my output should be "OK" and if value of first 2 number of A1 starts with 45 then my output should be "GREAT" and if value of first 2 number of A1 starts with 78 then output should be "FANTASTIC".
    Thank you.

    1. Hello!
      The formula below will do the trick for you:

      =IF(--LEFT(A1,2)=12,"OK",IF(--LEFT(A1,2)=45,"Great",IF(--LEFT(A1,2)=78,"FANTASTIC","")))

      I hope this will help

  46. Hi,
    Can anyone help me with this formula? I've been trying to create a Nested IF OR but just can't get it to work. I have a table with "Team" as a column heading in column A. I've added column D to the table for the office group. If column A is ftl, gai, or orl then column D should be fl. If column A is glf or nol then column D should be gcn. If column A is atl then column D should be geo. This is my formula but the result is always #VALUE!. Please help!
    =IF(OR([@Team]="ftl",[@Team]="gai",[@Team]="orl"),"fl"),IF(OR([@Team]="glf",[@Team]="nol","gcn"),IF(OR([@Team]="atl","geo"))

    1. Hello Sue!
      If I understand your task correctly, the following formula should work for you:

      =IF(OR(A1="ftl",A1="gai",A1="orl"),"fl",IF(OR(A1="glf",A1="nol"),"gcn",IF(A1="atl","geo","")))

      or IF function can be replaced with INDEX + MATCH functions

      =IFERROR(INDEX({"fl","fl","fl","gcn","gcn","geo"},MATCH(A1,{"ftl","gai","orl","glf","nol","atl"},0)),"")

      I hope it’ll be helpful.

      1. You're a Genius! I used the Index Match and it works perfectly! I never would have figured it out on my own. Thank you so much!!

  47. HI there I have inherited a daily cash reconciliation file which was updated manually on a daily basis. I'm trying to automate or create a formula and was wondering whats the best way to approcah this. So I have a list of transactions which I need to separate by Deposits, Wires Rcvd, Incoming Transfers, (Checks/wires)Paid, & Outgoing Transfers. Thank you!

      1. Post Date Check Description Debit Credit Status Balance Keyword Categories
        07/24/2020 SHINE MEDICAL CORP PAY VALCOR ENGINEERING 21022.00 Posted =INDEX(K2:K15,MATCH(TRUE,ISNUMBER(SEARCH(J2:J15,C2)),0)) SHINE MEDICAL CORP PAY VALCOR ENGINEERING WIRE
        07/24/2020 TA INSTRUMENTS-W DIR-DEPT VALCOR SCIENTIFIC 7200.00 Posted =INDEX(K2:K15,MATCH(TRUE,ISNUMBER(SEARCH(J2:J15,C2)),0)) TA INSTRUMENTS-W DIR-DEPT WIRE
        07/24/2020 ORBITAL SCIENCES EFT ID: 400742 0005VALCOR ENGINEERI 705ISA*00* *00* 25594.00 Posted =INDEX(K2:K15,MATCH(TRUE,ISNUMBER(SEARCH(J2:J15,C2)),0)) ORBITAL SCIENCES EFT WIRE
        07/24/2020 THE BOEING CO BCAGPAYSVC ID: 0006433532 0011VALCOR ENGINEERI 705ISA*00* *00* 16480.00 Posted =INDEX(K2:K15,MATCH(TRUE,ISNUMBER(SEARCH(J2:J15,C2)),0)) THE BOEING CO BCAGPAYSVC WIRE
        07/24/2020 UNEX DISB PAYABLES ID: VALCOR VALCOR ENGINEERING COR 705 10878.00 Posted =INDEX(K2:K15,MATCH(TRUE,ISNUMBER(SEARCH(J2:J15,C2)),0)) UNEX DISB WIRE
        07/23/2020 108572 CHECK NUMBER 108572 1245472250 972.10 Posted =INDEX(K2:K15,MATCH(TRUE,ISNUMBER(SEARCH(J2:J15,C2)),0)) CHECK NUMBER CHECKS PAID
        07/23/2020 108341 CHECK NUMBER 108341 1245598400 10553.34 Posted =INDEX(K2:K15,MATCH(TRUE,ISNUMBER(SEARCH(J2:J15,C2)),0)) TRANSFER TO CK# 41337204 OUTGOING TRANSFER
        07/23/2020 TRANSFER TO CK# 41337204 826257.04 Posted =INDEX(K2:K15,MATCH(TRUE,ISNUMBER(SEARCH(J2:J15,C2)),0)) PRINCIPAL LIFE WIRE
        07/23/2020 PRINCIPAL LIFE P PLIC-PERIS ID: 7-1454400004529 NO NAME ON FILE 76421.81 Posted =INDEX(K2:K15,MATCH(TRUE,ISNUMBER(SEARCH(J2:J15,C2)),0)) Medivators Inc. EDI PYMNTS WIRE
        07/23/2020 PRINCIPAL LIFE P PLIC-PERIS ID: 7-1454400004530 NO NAME ON FILE 9064.99 Posted =INDEX(K2:K15,MATCH(TRUE,ISNUMBER(SEARCH(J2:J15,C2)),0)) MERCHANT BANKCD DEPOSIT DEPOSITS
        07/23/2020 PRINCIPAL LIFE P PLIC-PERIS ID: 7-1454400004528 NO NAME ON FILE 1750.00 Posted =INDEX(K2:K15,MATCH(TRUE,ISNUMBER(SEARCH(J2:J15,C2)),0)) Accessory Tech WIRE
        07/23/2020 Medivators Inc. EDI PYMNTS ID: 01-102020000123 0012VALCOR ENGINEERI 705ISA*00* *00* 96770.50 Posted =INDEX(K2:K15,MATCH(TRUE,ISNUMBER(SEARCH(J2:J15,C2)),0)) PARKER EDI/ACH WIRE
        07/23/2020 MERCHANT BANKCD DEPOSIT ID: 447201760884 VALCOR ENGINEERING COR 6255.50 Posted =INDEX(K2:K15,MATCH(TRUE,ISNUMBER(SEARCH(J2:J15,C2)),0)) NORTHROP GRUMMAN EFT PMT WIRE

        Hi Alex, I'm trying to create a Index formula for where it returns the category of the expense but unfortunately it's not working properly could you please assist?
        Thanks,
        Anees

        1. Hello!
          I'm sorry, it is not very clear what result you want to get. Could you please describe your task in more detail and send us a small sample workbook with the source data and expected result to support@ablebits.com? Please shorten your tables to 10-20 rows/columns and include the link to your blog comment.

          We'll look into your task and try to help.

  48. This formula result: #VALUE!.
    =IF(OR(AND(A4="APPLE",B4="ORANGE"),"DRINK",IF(AND(A4="BREAD",B4="BUTTER"),"EAT")))
    Could you please fix it? The expected result is: DRINK, BUTTER, OR FALSE (either one).
    Thank you in advance.

    1. Hello!
      If I understand your task correctly, the following formula should work for you:

      =IF(AND(A4="APPLE",B4="ORANGE"),"DRINK", IF(AND(A4="BREAD",B4="BUTTER"),"EAT"))

      I hope it’ll be helpful.

      1. Thanks a lot, Alexander.
        It works perfectly!
        Have a nice day.
        Cheers,

  49. Hi,
    Can anyone please help me with my formula.
    I need "Yes" or "No" answer if the number in cell matches a number from any cell in another selected field. These two i have tried so far, but no luck.
    And sorry, my excel is in German.
    =WENN(A13=Tabelle1!A2:A29;"ja";"nein")
    =WENN(B16="SVERWEIS('INT-B-106 Kennzahlen nach Artik'!A13;Tabelle1!A:A;1;Tabelle1!A:A)";"ja";"nein")

    Thanks for help and have a great day!

    1. Hello!
      I propose to use the following formula (in English):

      =IF(SUM(--(IF(A13=Tabelle1!A2:A29,1,0)))>0,"yes","no")

      I hope this will help

  50. I need help in finalizing this formula. =IF(AND(L10>=1,L10<=10),250,SUM(L10-10)*11+250), IF(L10<1,0,""). The formula works great up to the last IF statement. I am needing it to return 0 if L10 is less than one or in other words equal to zero.

    1. Hello!
      If I understand your task correctly, the following formula should work for you:

      =IF(AND(L10>=1,L10<=10),250,IF(L10<1,0,SUM(L10-10)*11+250))

      I hope this will help

Post a comment



Thank you for your comment!
When posting a question, please be very clear and concise. This will help us provide a quick and relevant solution to
your query. We cannot guarantee that we will answer every question, but we'll do our best :)