简体   繁体   中英

VLOOKUP is not returning the right value

I have 2 sheets " Manually Transacted " and " Unread Tags " both have the same column Plaza , Lane , Date , Tag . All data in "Unread Tags" sheet are in "Manually Transacted" sheet but I have to find out which one it is in the "Manually Transacted" sheet. I created a column in "Manually Transacted" sheet called Column to place my VLOOKUP formula so I can compare the data to the "Uread Tags". This is how I created my VLOOKUP

=VLOOKUP([@Tag];Table2;4;FALSE)

For some reason, I get #N/A . I am sure that all my data in "Manually Transacted" sheet is in the "Unread Tags" sheet.

在此处输入图片说明

在此处输入图片说明

Can you please show me what I am doing wrong? Thank you.

You don't need Vlookup if you are looking at just one column. Vlookup also needs the lookup column as the first column of the lookup table, because it can only look to the left.

Also, since the correct result would return the same tag, it doesn't really make much sense to return that.

If you want to see if a Tag in one table has a match in another table, then you can use Match

=if(isnumber(match([@Tag],Table2[Tag],0)),"match","no match")

In words: find the Tag form the current row in the column "Tag" of Table2.

A match will return the position number. So, if the result is a number, you have a match. After copying down, you can filter the table for "no match" to see which numbers are missing.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM