=IF(MATCH(J1492,books!$A$1:$Z$300),"",1)

kylefoley76

Well-known Member
Joined
Mar 1, 2010
Messages
1,553
I can't figure out what's wrong with the above formula. It's coming back #N/A. I'm trying to return a blank if the value in J matches any word found on the books! spreadsheet, and 1 if the value in J is never found on the books spreadsheet.
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
If match returns n/a then the formula it's in will also return n/a if you don't use an error handling function.

=IF(ISNUMBER(MATCH(J1492,books!$A$1:$Z$300)),"",1)

alternatively try

=if(countif(books!$A$1:$Z$300,J1492),"",1)
 
Last edited:
Upvote 0
I can't get it to work. This is very bizarre. It worked for two values, but it did not work for some other values and it clearly should.

I'm using this code

=IF(ISNUMBER(MATCH(J1492,books!$A$1:$AZ$300)),"",1)

and it's showing that none of them match.

When I change it to

=IF(ISNUMBER(MATCH(J1492,books!$h$1:$h$300)),"",1)

It will work for two of 9 values, but one of the values is not even in column h
 
Upvote 0
Something I didn't notice before, match is no use for what you want, it only works with a single row / column. A1:A300 would work, as would A1:AZ1, but that would mean many formula for each cell.

In addition, MATCH(J1492,books!$h$1:$h$300,0) you didn't have exact match specified so it was accepting the closest.

If you try the alternative I suggested that should work with no problems.
 
Upvote 0
Ok, I got 9 columns, so maybe I can do it in one formula. I tried it for these columns but it didn't work

=IF(ISNUMBER(MATCH(J1499,books!$D$1:$D$300&books!$H$2:$H$300&books!$K$1:$K$300,0)),"",1)

It's returning 1 for everything and it should be returning blanks
 
Upvote 0
Why are you so determined to use match when i've already said it's the wrong function for the task, and given you an alternative that will work.

=if(countif(books!$A$1:$Z$300,J1492),"",1)
 
Upvote 0

Forum statistics

Threads
1,224,521
Messages
6,179,275
Members
452,902
Latest member
Knuddeluff

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