如果某些值在另一个 Excel 范围内重复,如何从列中返回适当的值?

如果某些值在另一个 Excel 范围内重复,如何从列中返回适当的值?

看看这个图片:Excel 图像
或者查看这个“图片转文字”示例表:

+--------------------+-----+------------+------------+------------+------------+
| Coolie Ghost       |     | New Frames | Brown N    | Red N      | Gray N     |
+--------------------+-----+------------+------------+------------+------------+
| Frame 4086         | Yes | Frame 2978 | Frame 3938 | Frame 3366 | Frame 3995 |
+--------------------+-----+------------+------------+------------+------------+
| Sprite number = 86 | No  | Frame 2979 | Frame 3328 | Frame 3367 | Frame 3996 |
+--------------------+-----+------------+------------+------------+------------+
| Subnumber = 7      | No  | Frame 2980 | Frame 2909 | Frame 4088 | Frame 3997 |
+--------------------+-----+------------+------------+------------+------------+
| Frame 4087         | Yes | Frame 2981 | Frame 3939 | Frame 3369 | Frame 4086 |
+--------------------+-----+------------+------------+------------+------------+
| Sprite number = 87 | No  | Frame 2982 | Frame 4087 | Frame 3370 | Frame 3998 |
+--------------------+-----+------------+------------+------------+------------+
| Subnumber = 8      | No  | Frame 2983 | Frame 3273 | Frame 3371 | Frame 3999 |
+--------------------+-----+------------+------------+------------+------------+
| Frame 4088         | Yes | Frame 2984 | Frame 3940 | Frame 3381 | Frame 4000 |
+--------------------+-----+------------+------------+------------+------------+

B 列范围B2:B8YesNo值。它是此类函数的结果:
=IF(COUNTIF($D$2:$F$8;A2);"Yes";"No")。换句话说,如果 A 列数据在D2:F8范围内有重复项,则它会输出Yes

我需要的是,它会按从上到下的递增顺序Yes返回值:等等。通过拖动自动填充单元格,值可以是列值或空值。通过这样做,我将知道重复值到底在哪里,以及可以使用哪些可能的非重复值。它将位于列旁边的下一个相邻单元格中。New FramesFrame 2978, Frame 2979, Frame 2980New FramesBA

另外,您能告诉我如何A2:A8通过从自动填充来自动更改实际重复单元格值A2吗?而不是Frame 4086, Frame 4087, Frame 4088从上到下A2使用New FramesFrame 2978, Frame 2979, Frame 2980等等。----

2021-01-25 编辑:

我想补充一点,很遗憾 excel 不理解这样的函数公式:=IF(COUNTIF($D$2:$F$8;A2);C(1+COUNTIF($B$2:B2; $B$2));"")

单元格C(formula),一个公式,可以选出正确的单元格。可以是 或C1C2C3。单元格名称由列坐标字母和行号组成。单元格坐标是单元格值的引用。所以我的C(将是列,但行号应该由公式计算1+COUNTIF($B$2:B2; $B$2)。但 Excel 不理解这样的单元格分配。也许我不了解如何正确地做到这一点。我想要的结果是这样的:

+--------------------+--------------+--------------+--------------+--------------+--------------+
|   Coolie   Ghost   |              |  New Frames  |  Brown N     |  Red N       |    Gray N    |
+--------------------+--------------+--------------+--------------+--------------+--------------+
|      Frame 4086    |  Frame 2978  |              |  Frame 3938  |  Frame 3366  |  Frame 3995  |
+--------------------+--------------+--------------+--------------+--------------+--------------+
| Sprite number = 86 |              |              |  Frame 3328  |  Frame 3367  |  Frame 3996  |
+--------------------+--------------+--------------+--------------+--------------+--------------+
|    Subnumber = 7   |              |              |  Frame 2909  |  Frame 4088  |  Frame 3997  |
+--------------------+--------------+--------------+--------------+--------------+--------------+
|     Frame 4087     |  Frame 2979  |  Frame 2981  |  Frame 3939  |  Frame 3369  |   Frame 4086 |
+--------------------+--------------+--------------+--------------+--------------+--------------+
| Sprite number = 86 |              |  Frame 2982  |  Frame 4087  |  Frame 3370  |  Frame 3998  |
+--------------------+--------------+--------------+--------------+--------------+--------------+
|    Subnumber = 7   |              |  Frame 2983  |  Frame 3273  |  Frame 3371  |   Frame 3999 |
+--------------------+--------------+--------------+--------------+--------------+--------------+
|     Frame 4088     |  Frame 2980  |  Frame 2984  |  Frame 3940  |  Frame 3381  |   Frame 4000 |
+--------------------+--------------+--------------+--------------+--------------+--------------+

如何从第一个表实现?使用类似 excel 函数?

相关内容