简体   繁体   English

VLOOKUP无法查找数据

[英]Trouble with VLOOKUP not finding data

Col A has ItemID Col B has Model_Num Col C has a long list of Model_Num . 柱A具有ItemID色柱B具有Model_Num山口C具有一长串Model_Num In Col DI want to lookup the Model_Num of Col C and put the ItemID 在Col DI中,想要查找Col C的Model_Num并放入ItemID

item_id (colA)        model_num (colB)   to match (colC)  new data (colD)
--------              ----------         ---------        ---------
870834                FD021              KPA8A            14667122
16595156              S3TA03B            BW01B            #N/A
10752514              FD1424B            GM1500B          #N/A
10756167              SU03B              TA021            #N/A
14667130              KDAD               FD021            870834
14667122              KPA8A              FD021            870834

In the new data column (colD) I'm using the formula: 在新数据列(colD)中,我正在使用以下公式:

=VLOOKUP(C1,$A$1:$B$114,2,FALSE)

It's returning #N/A for everything though. 它虽然回归了#N/A Any help is appreciated. 任何帮助表示赞赏。

You have a mistake in your VLOOKUP formula and/or the way your data is organized by column. 您的VLOOKUP公式中存在错误和/或按列列出数据的方式。 VLOOKUP can not be used to look up values to the left of the lookup value in the VLOOKUP table - you would have to use an INDEX/MATCH function to do that - or you could just do this. VLOOKUP不能用于查找VLOOKUP表中查找值左侧的值 - 您必须使用INDEX / MATCH函数来执行此操作 - 或者您可以这样做。

1) You could cut and insert your column A(item_iD) to the right of your current column B(model_num). 1)您可以将列A(item_iD)剪切并插入当前列B(model_num)的右侧。 Then adjust your VLOOKUP formula appropriately. 然后适当调整您的VLOOKUP公式。 (So basically your item_id and model_num columns are backwards currently). (所以基本上你的item_id和model_num列目前是倒退的)。

If you want to keep your column order "as is" then you will need to use an INDEX/MATCH function which I can certainly provide: 如果你想保持你的列顺序“按原样”,那么你需要使用我当然可以提供的INDEX / MATCH函数:

=INDEX($A$1:$B$114,MATCH(C1,$B$1:$B$114,0),1)

Leave your data as is and put that in the top cell column D and then autofill down. 将数据保留原样并将其放在顶部单元格列D中,然后自动填充。 It should give you what you want. 它应该给你你想要的。

Good Luck. 祝好运。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

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