[英]Excel lookup value in all rows, not just 1st match
I have the following table with columns ID and X1, and I want to obtain X2.我有下表的 ID 和 X1 列,我想获得 X2。
If one row is YES in the X1 column, then in X2 column all rows with that same ID should be YES.如果 X1 列中有一行是 YES,那么在 X2 列中具有相同 ID 的所有行都应该是 YES。 Otherwise it should be NO.否则它应该是NO。 For example, ID=106629-1 (yellow) has 2 rows with NO but 1 with YES, then all three should be YES in X2 column.例如,ID=106629-1(黄色)有 2 行是 NO,但有 1 行是 YES,那么在 X2 列中这三行都应该是 YES。 The other 2 IDs (orange and blue) have all rows with NO, then X2 should be NO as well.其他 2 个 ID(橙色和蓝色)的所有行都为 NO,那么 X2 也应该为 NO。
I've tried VLOOKUP
, but it only considers the 1st match.我试过VLOOKUP
,但它只考虑第一场比赛。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.