根据条件返回列中的值 Use Ifs 或 Hlookup, Vlookup

时间:2021-05-11 03:35:54

标签: excel excel-formula google-sheets-formula

我尝试将J列中的数据返回到表中,如果“课程数”相等且列名“F1,F2,F3”与“流量”列中的数据相等,我使用IF但它只申请1个cell,怎么用IF或者其他方法?

我的尝试: =IF(and($C3=H4, D$2= I4),$J4,false) enter image description here

1 个答案:

答案 0 :(得分:0)

关于如何使用一个公式完成此操作有多种版本

情况 1:将此公式复制到单元格 D3

=ArrayFormula(sumif(H4:H15&I4:I15,C3:C11&D2:F2,J4:J15))

enter image description here

情况 2:如果您确实需要指定 False 而不是零值,则将此公式写入单元格 D3

=ArrayFormula(REGEXREPLACE(TO_TEXT(sumif(H4:H15&I4:I15,C3:C11&D2:F2,J4:J15)),"^0$","False"))

enter image description here

相关问题