The tutorial shows how to combine VLOOKUP and IF function together to v-lookup with if condition in Excel. You will also learn how to use IF ISNA VLOOKUP formulas to replace #N/A errors with your own text, zero or blank cell.
Whilst the VLOOKUP and IF functions are useful on their own, together they deliver even more valuable experiences. This tutorial implies that you remember the syntax of the two functions well, otherwise you may want to brush up on your knowledge by following the above links.
Vlookup with If statement: return True/False, Yes/No, etc.
One of the most common scenarios when you combine If and Vlookup together is to compare the value returned by Vlookup with a sample value and return Yes / No or True / False as the result.
In most cases, the following generic formula would work nicely:
Translated in plain English, the formula instructs Excel to return True if Vlookup is true (i.e. equal to the specified value). If Vlookup is false (not equal to the specified value), the formula returns False.
Below you will a find a few real-life uses of this IF Vlookup formula.
Example 1. Look up a specific value
Let's say, you have a list of items in column A and quantity in column B. You are creating a dashboard for your users and need a formula that would check the quantity for an item in E1 and inform the user whether the item is in stock or sold out.
You pull the quantity with a regular Vlookup with exact match formula like this:
=VLOOKUP(E1,$A$2:$B$10,2,FALSE)
Then, write an IF statement that compares Vlookup's result with zero, and returns "No" if it is equal to 0, "Yes" otherwise:
=IF(VLOOKUP(E1,$A$2:$B$10,2,FALSE)=0,"No","Yes")
Instead of Yes/No, you can return TRUE/FALSE or In Stock/Sold out or any other two choices. For example:
=IF(VLOOKUP(E1,$A$2:$B$10,2)=0,"Sold out","In stock")
You can also compare the value returned by Vlookup with sample text. In this case, be sure to enclose a text string in quotation marks, like this:
=IF(VLOOKUP(E1,$A$2:$B$10,2)="sample text",TRUE,FALSE)
Example 2. Compare Vlookup result with another cell
Another typical example of Vlookup with If condition in Excel is comparing the Vlookup output with a value in another cell. For example, we can check if it's greater than or equal to a number in cell G2:
=IF(VLOOKUP(E1,$A$2:$B$10,2)>=G2,"Yes!","No")
And here is our If formula with Vlookup in action:
In a similar fashion, you can use any other logical operator together with a cell reference in your Excel If Vlookup formula.
Example 3. Vlookup values in a shorter list
To compare each cell in the target column with another list and return True or Yes if a match is found, False or No otherwise, use this generic IF ISNA VLOOKUP formula:
If Vlookup results in the #N/A error, the formula returns "No", meaning the lookup value is not found in the lookup list. If the match is found, "Yes" is returned. For example:
=IF(ISNA(VLOOKUP(A2,$D$2:$D$4,1,FALSE)),"No","Yes")
If your business logic requires the opposite results, simply swap "Yes" and "No" to reverse the formula's logic:
=IF(ISNA(VLOOKUP(A2,$D$2:$D$4,1,FALSE)),"Yes","No")
Excel If Vlookup formula to perform different calculations
Besides displaying your own text messages, If function with Vlookup can perform different calculations based on the criteria you specify.
Taking our example further, let's calculate the commission of a specific seller (F1) depending on their effectiveness: 20% commission for those who made $200 and more, 10% for everyone else.
For this, you check if the value returned by Vlookup is greater than or equal to 200, and if it is, multiply it by 20%, otherwise by 10%:
=IF(VLOOKUP(F1,$A$2:$C$10,3,FALSE )>=200, VLOOKUP(F1,$A$2:$C$10,3,FALSE)*20%, VLOOKUP(F1,$A$2:$C$10,3,FALSE)*10%)
Where A2:A10 are seller names and C2:C10 are sales.
IF ISNA VLOOKUP to hide #N/A errors
If the VLOOKUP function cannot find a specified value, it throws an #N/A error. To catch that error and replace it with your own text, embed a Vlookup formula in the logical test of the IF function, like this:
Naturally, you can type any text you like instead of "Not found".
Supposing, you have a list of seller names in one column and sales amounts in another column. Your task is to pull a number corresponding to the name the user enters in F1. If the name is not found, display a message indicating so.
With the names in A2:A10 and amounts C2:C10, the task can be fulfilled with the following If Vlookup formula:
=IF(ISNA(VLOOKUP(F1,$A$2:$C$10,3,FALSE)), "Not found", VLOOKUP(F1,$A$2:$C$10,3,FALSE))
If the name is found, a corresponding sales amount is returned:
If the lookup value is not found, the Not found message appears instead of the #N/A error:
How this formula works
The formula's logic is very simple: you use the ISNA function to check Vlookup for #N/A errors. If an error occurs, ISNA returns TRUE, otherwise FALSE. The above values go to the logical test of the IF function, which does one of the following:
- If the logical test is TRUE (#N/A error), your message is displayed.
- If the logical test is FALSE (lookup value is found), Vlookup returns a match normally.
IFNA VLOOKUP in newer Excel versions
Beginning with Excel 2013, you can use the IFNA function instead of IF ISNA to catch and handle #N/A errors:
In our example, the formula would take the following shape:
=IFNA(VLOOKUP(F1,$A$2:$C$10,3, FALSE), "Not found")
Tip. If you'd like to trap all sorts of errors, not only #N/A, use VLOOKUP in combination with the IFERROR function. More details can be found here: IFERROR VLOOKUP in Excel.
Excel Vlookup: if not found return 0
When working with numerical values, you may want to return a zero when the lookup value is not found. To have it done, use the IF ISNA VLOOKUP formula discussed above with a little modification: instead of a text message, supply 0 in the value_if_true argument of the IF function:
In our sample table, the formula would go as follows:
=IF(ISNA(VLOOKUP(F2,$A$2:$C$10,3,FALSE)), 0, VLOOKUP(F2,$A$2:$C$10,3,FALSE))
In the recent versions of Excel 2016 and 2013, you can use the IFNA Vlookup combination again:
=IFNA(VLOOKUP(I2,$A$2:$C$10,3, FALSE), 0)
Excel Vlookup: if not found return blank cell
This is one more variation of the "Vlookup if then" statement: return nothing when the lookup value is not found. To do this, instruct your formula to return an empty string ("") instead of the #N/A error:
Below are a couple of complete formula examples:
For all Excel versions:
=IF(ISNA(VLOOKUP(F2,$A$2:$C$10,3,FALSE)), "", VLOOKUP(F2,$A$2:$C$10,3,FALSE))
For Excel 2016 and Excel 2013:
=IFNA(VLOOKUP(F2,$A$2:$C$10,3, FALSE), "")
If with Index Match - left vlookup with If condition
Experienced Excel users know that the VLOOKUP function is not the only way to do vertical lookup in Excel. The INDEX MATCH combination can also be used for this purpose and it's even more powerful and versatile. The good news is that Index Match can work together with IF in exactly the same way as Vlookup.
For example, you have order numbers in column A and seller names in column B. You are looking for a formula to pull the order number for a specific seller.
Vlookup cannot be used in this case because it cannot search from right to left. Index Match will work without a hitch as long as the lookup value is found in the lookup column. If not, a #N/A error will show up. To replace the standard error notation with your own text, nest Index Match inside IF ISNA:
=IF(ISNA(INDEX(A2:A10, MATCH(F1, $B$2:$B$10, 0))), "Not found", INDEX(A2:A10, MATCH(F1, $B$2:$B$10, 0)))
In Excel 2016 and 2016, you can use IFNA instead of IF ISNA to make the formula more compact:
=IFNA(INDEX(A2:A10, MATCH(F1, $B$2:$B$10, 0)), "Not found")
In a similar manner, you can use Index Match in other If formulas.
This is how you use Vlookup and IF statement together in Excel. To have a closer look at the formulas discussed in this tutorial, you are welcome to download our sample workbook below. I thank you for reading and hope to see you on our blog next week!
Practice workbook for download
Excel IF Vlookup - formula examples (.xlsx file)
375 comments
Hi, can someone please try to help me.. So I got 2 criteria.
I am wanting to automate invoice dates based on criteria. Delivery and Activation date.
I already created helper column for the delivery and activation dates. Now I just want to formulate and not look manually. So I got items that needs to have invoice date +1yr from the payment date if they have no invoice or activation date.. Can someone please assist me?
Payment Date Column A
Invoice Number Column B
Activation Helper Column Q
Delivery Date Helper Column R
Invoice Date Ref Column P
So on Column P,I got delivery and activation date, if invoice was Activation date,then there is activation code on Column Q, invoice date should be payment Date, if the Activation Helper Says No, invoice date should be +1yr from payment date.
Same with the delivery date, if there is a delivery date on Column R, the invoice date should be delivery date,if not delivery date,should be +1yr from payment date
Hi! From your explanation, it is not quite clear what is written in column P - Invoice Date Ref or delivery and activation date.
Use the IF formula to set the value of a cell based on a condition. For example:
=IF(Q2="yes",P2,EDATE(P2,12))
To add 1 year to the date, you can use these instructions: Excel EDATE function to add or subtract months from date.
You can also use these recommendations: Add years to date in Excel.
Hi,
Do you know how can I create a formula with multiple criteria but with same result? i.e.: I have "John, Martha, Kevin, Robert", but I want to show that only "John and Kevin" are "Active users", no comments for the other two.
Hello Guilhermo!
Unfortunately, this information is not enough to recommend a formula to you. It's unknown what your definition of active users is, what your source data is, and what the expected result is.
I have a monthly time sheet for a single staff member in South Africa. Her hours are flexible and that makes the tax rate differ monthly.
Once I have her monthly figure from the hours worked I need to refer to a table provided by SARS (tax) and if her earnings are between X and Y then I choose that value.
How do I set up my excel to automatically access the table (I have retyped the rows/columns that would be relevant (base remuneration, top remuneration, tax rate). So for example:
If she earned R9287 in the month I would look at the table row where the salary falls between R9222 and R9322 and select the tax figure of R233.
I would like the system to do this for me. HELP.
Thanks.
Hello Janet!
To check that a number is within a certain interval, use approximate match. We have special tutorials on this. Please see: How to Vlookup for approximate match and Approximate match XLOOKUP.
The data you have provided is not enough to offer you a formula.
Thank you Alexander. I will give it a go and come back to you with more details if I get stuck again.
I want to check if there is a formula for returning value as 0 or blank, if the value has already been looked up.
For example, lookup value is in Column A, some are duplicated, some are not. So if I want to look up the value of "123x", I do the formula on Row1 ColB. But for Row 2, I want it to return value as zero, since its already been looked up in Row 1. Can I do that? Thanks in advance.
Col A
Row 1 123x
Row 2 123x
Row 3 123x
Row 4 124B
Hello Juli!
I can't guess what you want to get if the value you are looking for is found. To find only the first match, you can use the COUNTIF function.
=AND(COUNTIF($A$1:$A1,"123x")=1,A1="123x")
This formula will return TRUE. Copy this formula down along the column.
I understand the scenario I also need help in this situation, basically if the first lookup value has been found the other lookup value with same text or number will just result to zero
Hello Paul!
If I understand your question correctly, to get 1 or 0 instead of TRUE or FALSE, use a math operation. Read more: Change Excel string to number with mathematic operations. For example:
=--AND(COUNTIF($A$1:$A1,"123x")=1,A1="123x")
You can also find useful information in this article: How to highlight duplicate cells and rows in Excel. The formula might look like this:
=--(COUNTIF($A$1:$A1,A1)<=1)
Hi - I want to do a if vlookup that if true the cell will populate with text from another sheet. example. If these people signed up for math class, populate the cell with the name of the person who signed up. so check the column for yes math class then add the name of the person in the cell. Thanks!!
Hi! Information you provided is not enough to understand your case. Try using recommendations from the article above. You may also find this guide useful: Vlookup from another sheet. If this does not solve the problem, try explaining the problem in more detail.
Hi. Ok let me try again :)
Sheet 1 has a list of people signed up for multiple classes, Friday at 4-5pm, Friday 5-6pm, Monday 5:30-7pm, etc. I want to look up who is signed up for Friday at 4-5pm class. If the vlookup is true and a person signed up I want the persons' name to be displayed in the cell of the if vlookup formula instead of just "yes". Hopes this makes sense! Thanks
Hi! I can't recommend a formula for you as I can't see example your data. However, all the necessary recommendations to find a person's name by day of the week and time are in this article: Excel INDEX MATCH with multiple criteria - formula examples.
It will be much easier to find person's name that you need if the date and the time are written in different columns.
Hello ,
Would seek help, desperate trys but failed from past 3 months, Case is in a excel there are 40 sheets , First sheet has categories , and Subset of catergory has 5 sheets for each catergory,
i want to lookup if Value in Colum A is alphabet E then it should fist lookup for E in category sheet and then if Colum B is L as cell value then it should lookup in subset of Colum A (E is the value) , if first colum A has value of E then it should first search for e in catergory sheet and return the value, and then second cell colum B should be searched in Subset sheets of catergory sheet , please help !
Hello!
Your request goes beyond the advice we provide on this blog. This is a complex solution that cannot be found with a single formula. To create dynamic references to worksheets, ranges, or cells, you can use the INDIRECT function as described in this guide: How to use INDIRECT function in Excel - formula examples. If you have a specific question about the operation of a function or formula, I will try to answer it.
Sir
bloew details i have getting sheet 02 dd date on sheet 01 with same dd no and same bank name
Kindly suggest the formula ?
Sheet 01 main file
DD NO DATE BANK NAME
241 08-Jan-24 Hdfc Bank Ltd
241 16-Jan-24 Surat Mercantile Co-Op Bank Ltd
241 20-Jan-24 Surat District Co-Op Bank Ltd
244 12-Jan-24 Surat District Co-Op Bank Ltd
244 24-Jan-24 Hdfc Bank Ltd
245 02-Feb-24 Hdfc Bank Ltd
245 06-Feb-24 Bank Of India
248 16-Jan-24 Hdfc Bank Ltd
248 20-Jan-24 Hdfc Bank Ltd
255 10-Jan-24 Bank Of India
255 18-Jan-24 Surat District Co-Op Bank Ltd
260 16-Jan-24 Surat District Co-Op Bank Ltd
260 18-Jan-24 Surat District Co-Op Bank Ltd
SHEET 02 RESULT FILE
DD NO DATE BANK NAME
241 ?
241 ?
241 ?
244 ?
244 ?
245 ?
245 ?
248 ?
248 ?
255 ?
255 ?
260 ?
260 ?
Hi! To find a value based on two conditions, you can use the INDEX MATCH functions and this guide: Excel INDEX MATCH with multiple criteria - formula examples.
The formula might look like this:
=INDEX('Sheet 01'!B2:B10, MATCH(1,('Sheet 01'!A2:A10=A1)*('Sheet 01'!C2:C10=C1),0))
Respcted sir ,
no results found....
please help me
This formula on Sheet 01 searches for a date which meets two criteria: Bank Name and DD No. These criteria are on Sheet 02. If this is not what you need, tell me why and describe the problem in more detail.
Sir, i have Bank DD which is same number with Same bank or Other bank. I want to create a column on which date particular Bank DD was passed in clearing. I have Bank DD number, Bank Name and Bank Clearing Date. I tried but same value (duplicate-BANK DD same number) captured so how i trust that same Bank DD number was cleared on which date ?? so that is why i writing you for help. Can i share you my excelsheet on your e-mail id? please tell me and share your e-mail id... Thank You....
Hi! We do not work with user files. From your explanation, I don't understand why the proposed formula doesn't work for you.
sir,
below example the data sheet was two diffrent excel file below formula was apply ?
The formula works for two sheets.
Good morning,
This might not be possible and I'm struggling to search for it properly to find an answer and I hope I'm not confusing this too much, but I basically want a formula which uses the data in one cell to return a specific result, and if it doesn't match I want it to then vlookup to a specific range on a data sheet (so if the data in one cell matches it overrides the need to do the vlookup function, but if it doesn't match then it reverts to the vlookup) :
If data in Cell H12 = a certain phrase then return a specific text result.
But if the phrase doesn't match, then I want it to run through an if/or vlookup (I already have this formula and it works fine (below), but I want it to use the above condition as the primary source to return a result.
So the if/or vlookup formula I am using successfully is: =IF(OR($J$9="N",(VLOOKUP($F$16,Dropdowns!$G$4:$K$117,5,0))),"",VLOOKUP($F$16,Dropdowns!$G$4:$K$117,5,0))
But was then trying to also incorporate =IF($H$12="Service","Manager")
So if "Service" is selected from a drop down box in one cell, it returns "Manager" in the cell I want, but if a different option is selected like "Sales" or "Marketing" etc then it reverts to using the vlookup formula above to determine who the budget holder/approver would be.
Apologies, that probably all sounds a mess.
Many thanks!
Hi! If my understanding is correct, the following formula should work for you:
=IF($H$12="Service","Manager", IF(OR($J$9="N",(VLOOKUP($F$16,Dropdowns!$G$4:$K$117,5,0))),"",VLOOKUP($F$16,Dropdowns!$G$4:$K$117,5,0)))
Maybe this article will be helpful: Nested IF in Excel – formula with multiple conditions.
=IF(E4="LO",IF(L4="THW",VLOOKUP(H4,Table1,3),IF(L4="THHN",VLOOKUP(H4,Table2,3),IF(L4="SP","")))),IF(OR(E4="CO",E4="ACU"),IF(L4="THW",VLOOKUP(H4,Table1,3),IF(L4="THHN",VLOOKUP(H4,Table2,3),IF(L4="SP",""))))
SIr can you check my formula, it says Error in Value. thank you
Hi! I can't check a formula that contains unique references to your data, which I don't have.
I am working in a report that filters operations with defects found in production lines by product type following certain codes per product and operations. I am using pivot tables to condense all the data logged into said report.
I was asked to attach the number of operation to the names of the operations by a bulletin. So far I've gotten it to match just one style but I cannot get it to change the result depending on style. OP #15 can be "Attach Velcro" for Style#1 and "Make Hood" for Style #2. All styles are defined by codes too.
My report logs all the data in the following columns
Style# | Operation # | Operation description |
Example of what I am using in the Operation Description (which is where I need the value to change according to the style:
=(VLOOKUP(I13,BULLETIN!$A$1:$C$499,3,FALSE))
Bulletin is the name of the sheet where I have all the operations divided by product. I cannnot find a way to make the value change depending on the style, continues to give me error.
in the "Bulletin" sheet it is divided as follows:
Operation # | Style | Operation Description.
I hope that's clear.
Hi! If I understand your task correctly, you want to find an "Operation description" for both Style# and Operation#. To do this, use the two-criteria search.
You can find the examples and detailed instructions here: Excel INDEX MATCH with multiple criteria - formula examples.
I can't do a formula suggestion because I don't have your data.
Hello, please i am trying get an excel function that will look through column A, compare its corresponding value in column B and return either PASS/FAIL under column C, assuming an expected minimum value under column B is expected after a specific curing days under column A.
E.g. if after 28 Days, the corresponding UCS value is 10.5 (which is below the expected minimum for 28 day period) then it returns FAIL under column C.
A B C
Curing Days UCS Results (MPa) PASS/FAIL
28 Days 27.3
7 Days 15.2
24 Hrs 27.3
24 Days 17.2
Hi! If I understand correctly, column A contains text. You need to extract a number from the text to compare it with other numbers. You can find the examples and detailed instructions here: How to extract number from string in Excel. For example:
=--LEFT(A2, MATCH(FALSE, ISNUMBER(MID(A2, ROW(INDIRECT("1:"&LEN(A2)+1)), 1) *1), 0) -1)
You can use this number in the IF formula, but the conditions are not very clear to me.
Hi, I have a table in which multiple columns are there. I need to search key word "P1" in column J and key word "Not Mapped" in column AN. If these two are matching then I should get output from column A which is unique ID. Can you please help me with the vlookup formula.
For Ex:
ID City1 City2 City3 City4 City5 City6 City7 City8 Priority Team1 Team2 Team3 Team4 Team5 Team6 Team7 Team8 Team9 Team10 Team11 Team12 Team13 Team14 Team15 Team16 Team17 Team18 Team19 Team20 Team21 Team22 Team23 Team24 Team25 Team26 Team27 Team28 Team29 Status
66050C24 P1 Not Mapped
56050C24 P2 Mapped
56050C24 P1 Mapped
In above example only first row satisfies the condition so it should fetch ID from column A i.e. 66050C24.
Hi! You can find the examples and detailed instructions here: Excel INDEX MATCH with multiple criteria. Based on your information, the formula might look something like this:
=INDEX(A2:A100, MATCH(1,(J2:J100="P1")*(AN2:AN100="Not mapped"),0))
Thank you for your swift response, really appreciate it.
I tried it but I am getting #SPILL! error message. Can you please help.
I got the output correctly.
Issue here is I have 100+ values which satisfies (J2:J100="P1")*(AN2:AN100="Not mapped") but I am getting output is first ID from column A. My ask is to fetch all IDs from column A which satisfies the condition (J2:J100="P1")*(AN2:AN100="Not mapped").
Hi! Try to follow the recommendations from this article: How to Vlookup multiple values in Excel with criteria. The formula might look like this:
=IFERROR(INDEX($A$2:$A$100, SMALL(IF(1=((--(J2:J100="P1"))*(--(AN2:AN100="Not mapped"))), ROW($A$2:$A$100)-1,""), ROW()-1)),"")
Also, to get a list of values by condition, you can use the FILTER function as described in this guide: Excel FILTER function with formula examples. For example:
=FILTER(A2:A100,(J2:J100="P1")*(AN2:AN100="Not mapped"))
Hello,
May I know how would I search my data in multiple columns? I have a dataset which I want to identify their function.. And each data have multiple functions which listed in multiple columns.
Eg; abc, cde, efg, ghi
Functions:
metabolism: cde, efg
Oxidative: abc, efg, ghi
Catabolism: abc, cde, efg, ghi
When I did the vlookup for ' abc' resulted N/A, cde - metabolism, efg-metabolism, ghi-N/A.
My formula as below:
=VLOOKUP(A2, 'C:\Functions'! $B:$C,2,0)
How can I make it go through other columns
So that every data have their exact function? If can't found in column 1, check in the rest of the columns until meet their function.
Thank you.
Hi! I don't really understand how you could get these results with your formula. I’ll try to guess and offer you a sequential search across multiple columns using these instructions: How to do sequential VLOOKUPs in Excel
=IFERROR(VLOOKUP(A2,$B:$C,2,0),VLOOKUP(A2,$B:$D,3,0))
or
=IFERROR(INDEX(A2:A10,MATCH(A1,B2:B10,0)),INDEX(A2:A10,MATCH(A1,C2:C10,0)))
If this is not what you wanted, please describe the problem in more detail.
Please help po for the formula.
I nee to know if the ID no. is certified on the process
ID No. Process Status
PH0001 Inspection Certified or not
Note: 1 ID no. have so many process i need to know the id no. is certified for the specific process
Hi! Based on your description, it is hard to completely understand your task. However, I’ll try to guess and offer you the following formula:
=VLOOKUP("PH0001",A1:B10,2,FALSE)="Inspection"
I have Item_Desc in Sheet1
Item 1, Item 2, Item 3
in other hand in Sheet2 I have Item_Desc, Bill_Date, Value
Item 1, 01/12/2023, 1050
Item 2, 11/12/2023, 850
Item 1, 51/12/2023, 950
Need Solution : I need in Sheet1 VlookUp Item1 of last Bill_Date from Sheet2.
Please solve my problem.
Hi! Try using the XLOOKUP function, which can do a reverse lookup from the last value to the first value:
=XLOOKUP("Item 1",A1:A10,C1:C10,,0,-1)
You can find the examples and detailed instructions here: Excel XLOOKUP function with formula examples.
Sample problem:
A B C D G
CUSTOMER CODE PREVIOUS AGING CURRENT AGING PD STATUS CANCELLED CUSTOMER
C001 121-150 D 31-60 D NO PAYMENT C004
C002 121-150 D 31-60 D NO PAYMENT
C003 121-150 D NOT FOUND UPDATED
C004 121-150 D NOT FOUND CANCELLED
Question: what is the formula to tag c0003 as updated then the c004 as cancelled while getting the current aging of c0011 & c002? Scenario: current aging list is found in sheet 2.
Unfortunately, this information is not enough to understand what you need. Please clarify your specific problem or provide additional information to understand your question.
I am trying to create a new reference column in a data set to say 'If cell from column B is found in the lookup table, then return text from cell B + cell E, otherwise return just the value/text from cell B' - It is working for some, but not others.
Can you help?
=IF(VLOOKUP(B11,$N$9:$N$12,1,TRUE)=B11,TEXTJOIN(" - ",,B11,E11),B11)
Hi! If the value B11 is not found, the VLOOKUP function will return an error. Use the IFERROR function to return only the B11 value in case of an error. Try this formula:
=IFERROR(TEXTJOIN(" - ",,VLOOKUP(B11,$N$9:$N$12,1,TRUE),E11),B11)
Hi,
I have a data set where in one column i have unique code, which needs to be mapped/looked-up in another tab but the data required is in multiple tables and i need to lookup that data based on the priority .
Example "qt3213e" is my unique key which can be available in more then 1 table but based on my priority is should 1st search in table 2 then table 1 and so on till it is found and return the value in front of it. How can this be done. Thanks.
Hi! You can use different VLOOKUP formulas depending on the cell value. You can use the nested IF formula or the IFS function for this purpose. For example:
=IFS(C1=1, VLOOKUP(......),C1=2, VLOOKUP( ........))
hai,
i have to vlookup and substitute the word from "COMPANY A" to "-"
can anyone help me?
how to add 2 formula in one column?
=VLOOKUP(E3,'MASTER INFO '!A2:D734,4,FALSE)
=SUBSTITUTE(A3, "COMPANY A", "-", 1)
Hi! You can't write two formulas in the same cell. I'm not quite sure what you want to look for. To replace the text in the cell, use the SUBSTITUTE formula. If that text is not found, the value will not change. You can use a reference to a range of cells, for example:
=SUBSTITUTE(A1:A10, "COMPANY A", "-", 1)
If this does not help, explain the problem in detail.
=IFS(VLOOKUP($B:$B,SMS!$B:$B,1,FALSE),"SMS",VLOOKUP($B:$B,Email!$B:$B,1,FALSE),"Email","Others")
Please help me with my problem, I have 3 worksheets, 1st Worksheet is all the data that is sent via SMS, 2nd worksheet is all data that is sent via Email, then the 3rd worksheet is the consolidated data of the clients who replied. I used vlookup to verify what mode did I use to reach that client. As of now, I individually use vlookup per client then if N/A, I manually put "Others". Thanks in advance.
A B C
No. Account Name
1 001 Asadf Akjs
Hi! Read these instructions: Excel VLOOKUP tutorial with formula examples. Try this formula:
=IFERROR(IFS(NOT(ISNA(VLOOKUP($B1,SMS!$B:$B,1,FALSE))),"SMS",NOT(ISNA(VLOOKUP($B1,Email!$B:$B,1,FALSE))),"Email"),"Others")
You can also find an explanation of the formula in this article: How to use ISNA in Excel with VLOOKUP. If both VLOOKUP functions return an error, you can use the IFERROR function to return the value "Others".
You can copy this formula down along the column.
It returns, FALSE. I appreciate your help, TYSM.