index and match return custom message if #NA

rjmdc

Well-known Member
Joined
Apr 29, 2020
Messages
672
Office Version
  1. 365
Platform
  1. Windows
hi
i got as far as to realize that index and match shouldnt have empty rows. i used power query to trim and clean so values are the same
index and match works but leaves me a messy sheet full of #NA
=INDEX('Vendors with Addresses'!A:A,MATCH([@[Tabs ID]],'Vendors with Addresses'!M:M,0))
how do i add custom message that if result is #NA instead "choose another method"
 

Excel Facts

How to show all formulas in Excel?
Press Ctrl+` to show all formulas. Press it again to toggle back to numbers. The grave accent is often under the tilde on US keyboards.
i got this far
=IF(IFERROR(INDEX('Vendors with Addresses'!A:A,MATCH([@[Tabs ID]],'Vendors with Addresses'!M:M,0)),"")="", "choose override",IFERROR(INDEX('Vendors with Addresses'!A:A,MATCH([@[Tabs ID]],'Vendors with Addresses'!M:M,0)),""))

however the entire column gets filled with the "override"
what am i missing to the formula that only if there is a field on [@[Tabs ID]] do formula i cant have an empty column filled
 
Upvote 0
How about
= IFERROR(INDEX('Vendors with Addresses'!A:A,MATCH([@[Tabs ID]],'Vendors with Addresses'!M:M,0)),"Choose override")
 
Upvote 0
hi
it still fills the entire column with "override"
how do i get the unfilled cells to be ""
 
Upvote 0
Does the formula you posted in your op return anything other than #N/A?
 
Upvote 0
no it also only gives me the "override"
 
Upvote 0
I'm talking about the original formula you posted in the op, not the formula you posted in post#2
 
Upvote 0
the first formula gave me NA and the 1 or 2 matches
 
Upvote 0
In that case the formula I supplied should do the same, but you would get Choose override instead of #N/A
 
Upvote 0
that is what happens, same as the formula i used
problem is the entire table even the unfilled rows gets filled with the overrride, is there a way for the ell to be blank unless it is actually used in the formula meaning cell A is filled in?
 
Upvote 0

Forum statistics

Threads
1,214,990
Messages
6,122,626
Members
449,094
Latest member
bsb1122

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