嵌套 if 函数在 arrayformula 中

Nested if functions in arrayformula

我在 Google 张中有这个公式 (1):

=IF($A2="","",IF(AND(($G2 <= EOMONTH(TODAY(),-5)),($G2 <> ""),OR($H2 > EOMONTH(TODAY(),-5),$H2 = ""),OR($E2 > EOMONTH(TODAY(),-5),$E2 = "")),1,0))

我想将其转换为数组公式。我尝试了这个公式 (2),但出现“#N/A 不匹配”错误:

=ARRAYFORMULA ( 
    IFs (
        ROW(A:A) = 1, "Contract Published, " & TEXT(EDATE(TODAY(),-5),"mmm-YY"),
        IF(AND((G:G <= EOMONTH(TODAY(),-5)),(G:G <> ""),OR(H:H > EOMONTH(TODAY(),-5),H:H = ""),OR(E:E > EOMONTH(TODAY(),-5),E:E = "")),1,0),)
)

我也试过这个公式 (3),但出现“公式解析错误”

=ARRAYFORMULA ( 
        IF(ROW(A:A) = 1, "Contract Published, " & TEXT(EDATE(TODAY(),-5),"mmm-YY")),
        IF((G:G <= EOMONTH(TODAY(),-5),G:G <> ""),
        IF((H:H > EOMONTH(TODAY(),-5),H:H = ""), 
        IF((E:E > EOMONTH(TODAY(),-5),E:E = "")),1,0)))

有谁知道我做错了什么,或者我如何将公式 (1) 转换为数组公式?

尝试第 2 行:

=ARRAYFORMULA(IF(A2:A="",,
 IF(((G2:G <= EOMONTH(TODAY(), -5))* 
     (G2:G <> "")*
     ((H2:H > EOMONTH(TODAY(), -5)) + (H2:H = ""))*
     ((E2:E > EOMONTH(TODAY(), -5)) + (E2:E = ""))), 1, 0)))