【问题标题】:In Excel: with an array, how to pull duplicate data?在 Excel 中:使用数组,如何提取重复数据?
【发布时间】:2016-03-12 20:51:44
【问题描述】:

当前数组:

{=IFERROR(INDEX(Data!$A$1:$C$2000,MATCH(1,(Data!$A$1:$A$2000='8157'!$C3)*(Data!$B$1:$B$2000='8157'!F$2),0),3),"")}

但是,这只会将 Kasper, John 拉到每个牢房中。我在第二个单元格中尝试了 OFFSET,但没有运气。有任何想法吗?谢谢!

数据表:

LOCATION    JOBTITLE                        NAME
67          Assistant Manager Merchandise   Kasper,John
67          Assistant Manager Merchandise   Montresor,Britney
67          Assistant Manager Operations    Eldred,Joshua O.

实际工作表: 标题横跨左上方和下方。使用上面的数组从数据表中提取的数据。 (注意 Kasper,John 是重复的,而不是拉 Montresor,Britney

Store # SVG General Manager Assistant Manager Merchandise   Assistant Manager Merchandise
67     5    Scudder,Debra        Kasper,John                    Kasper,John
168    4    Major,Stacey         Papp,Michael                   Papp,Michael

【问题讨论】:

  • 我的回答对你有用吗?如果是这样,请通过单击答案旁边的灰色/绿色复选标记标记为正确。这是只有你才能做的事情。

标签: arrays excel offset


【解决方案1】:

如果您有 excel 2010 或更高版本,请使用此非 CSE 公式:

=IFERROR(INDEX(Data!$A$1:$C$2000,AGGREGATE(15,6,Rows($1:$2000)/((Data!$A$1:$A$2000='8157'!$C3)*(Data!$B$1:$B$2000='8157'!F$2)),countif($F$2:F$2)),3),"")

如果您有 2007 年或更早的版本,请使用此 CSE 数组公式:

=IFERROR(INDEX(Data!$A$1:$C$2000,SMALL(IF(((Data!$A$1:$A$2000='8157'!$C3)*(Data!$B$1:$B$2000='8157'!F$2)),Rows($1:$2000)),countif($F$2:F$2)),3),"")

这需要用 Ctrl-Shift-Enter 确认。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 2019-05-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2017-03-14
    相关资源
    最近更新 更多