Nested IF statement with Vlookup - HELP PLEASE

janema

Board Regular
Joined
Nov 28, 2022
Messages
117
Office Version
  1. 365
  2. 2021
  3. 2019
  4. 2011
  5. 2010
Platform
  1. Windows
  2. Mobile
I have been trying to get this formula to work, but keep failing. I want excel to return a BLANK if it is an error or if the data from the source is blank. I am using a vlookup to pull the data so theoretically, if the result is an error ("IFERROR") or if the source data is blank, the end should return blank. So far, I have tried: =IFERROR(VLOOKUP(D210,'06.2022 file'!$B$1:$S$1000,13,FALSE),""),ISBLANK(LOOKUP(D210,'06.2022 file'!$B$1:$S$1000,13,FALSE),"") but it does not work. I also tried: =IFERROR(VLOOKUP(D210,'06.2022 file'!$B$1:$S$1000,13,FALSE),"",ISNA(VLOOKUP(D210,'06.2022 file'!$B$1:$S$1000,13,FALSE),"") but no luck. It returns a "0" when there is data source is blank, but I want it to just also be blank. How do I combine the two formulas without an error?

Please help!
 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.
You need to write it as

=IF(IFERROR(VLOOKUP(D210,'06.2022 file'!$B$1:$S$1000,13,FALSE),"")="","",VLOOKUP(D210,'06.2022 file'!$B$1:$S$1000,13,FALSE))

My laptop battery just died so I had to finish it on my phone and haven't been able to check the formula in excel, hopefully it is correct or at least close enough that you can figure out any correction it needs.
 
Upvote 0
Solution
You need to write it as

=IF(IFERROR(VLOOKUP(D210,'06.2022 file'!$B$1:$S$1000,13,FALSE),"")="","",VLOOKUP(D210,'06.2022 file'!$B$1:$S$1000,13,FALSE))

My laptop battery just died so I had to finish it on my phone and haven't been able to check the formula in excel, hopefully it is correct or at least close enough that you can figure out any correction it needs.

It just comes back as "FALSE" when I write that formula ☹️ This formula is driving me nuts! LOL

1669676249802.png
 
Upvote 0
That's not the same as the formula i posted, you're missing some double quotes in the middle.

edit: looks like you've moved a couple of bits as well, the = sign in the middle is after the wrong parentheses
 
Upvote 0
That's not the same as the formula i posted, you're missing some double quotes in the middle.

edit: looks like you've moved a couple of bits as well, the = sign in the middle is after the wrong parentheses
When I tried the original way it gave me an error and wouldn't let me apply it
 
Upvote 0
You need to write it as

=IF(IFERROR(VLOOKUP(D210,'06.2022 file'!$B$1:$S$1000,13,FALSE),"")="","",VLOOKUP(D210,'06.2022 file'!$B$1:$S$1000,13,FALSE))

My laptop battery just died so I had to finish it on my phone and haven't been able to check the formula in excel, hopefully it is correct or at least close enough that you can figure out any correction it needs.

I slightly changed it and it worked! Thank you so much! YOU ROCK!
 
Upvote 0
I think this formula is just enough for your need no matter the data is blank or the vlookup is error.
Excel Formula:
=IFERROR(VLOOKUP(D210,'06.2022 file'!$B$1:$S$1000,13,FALSE),"")
 
Upvote 0
I think this formula is just enough for your need no matter the data is blank or the vlookup is error.
Excel Formula:
=IFERROR(VLOOKUP(D210,'06.2022 file'!$B$1:$S$1000,13,FALSE),"")

Unfortunately, that formula does not work. It comes back as zero (0) when the source data is blank. I needed it to be blank for error or no source data.
 
Upvote 0
What version of Excel are you actually using?
 
Upvote 0

Forum statistics

Threads
1,215,455
Messages
6,124,935
Members
449,195
Latest member
Stevenciu

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top