如何在excel中合并以下两个ifs
公式?
=IF(AND( Sheet1!BC2<>"", Sheet1!CI2<>"",Sheet1!CA2=""),IF(Sheet1!CI2="","",Sheet1!CI2),IF(Sheet1!CA2="","",Sheet1!CA2)
=IF(AND( Sheet1!BC2="B",Sheet1!CI2<>""),IF(Sheet1!CI2="","",Sheet1!CI2),IF(Sheet1!CA2="","",Sheet1!CA2)
这两个公式都是单独正确的。
实际上它在第一个周期中是一个巨大的Excel表格,我用Sheet1!BC2<>"",Sheet1!CI2<>"",Sheet1!CA2=""
过滤并改变了数据。在下一阶段,我必须使用此条件Sheet1!BC2="B",Sheet1!CI2<>""
过滤并填充空白数据。虽然它们完全独立,但如何将它组合起来。
答案 0 :(得分:1)
[已编辑]试试这个:
=IF(AND( Sheet1!BC2<>"", Sheet1!CI2<>"",Sheet1!CA2=""),IF(Sheet1!BC2="B",Sheet1!CI2,Sheet1!CA2),IF(Sheet1!CA2="","",Sheet1!CA2))
答案 1 :(得分:0)
由于您生成的TRUE
和FALSE
IF
语句相同,我假设您只想在OR
语句中使用AND
语句}:
=IF(OR(AND(Sheet1!BC2<>"",Sheet1!CI2<>"",Sheet1!CA2=""),AND(Sheet1!BC2="B",Sheet1!CI2<>"")),IF(Sheet1!CI2="","",Sheet1!CI2),IF(Sheet1!CA2="","",Sheet1!CA2))