Google Sheet SUMIF not summing range

后端 未结 1 1409
南旧
南旧 2021-01-25 16:01

I am trying to SUM all rows based on the condition that a row\'s value is greater than 0. However, the formula is only calculating the first row and ignoring the rest of the ran

相关标签:
1条回答
  • 2021-01-25 16:35

    try:

    =ARRAYFORMULA(IF(A:A="",,SUMIF(ROW(A:A), "<="&ROW(A:A), A:A)))
    


    if you prefer dragging do:

    =SUMIF(INDIRECT("A1:A"&ROW()), ">0")
    


    UPDATE:

    =ARRAYFORMULA(IF(D2:D="",,
     SUMIF(ROW(D2:D), "<="&ROW(D2:D), D2:D)-
     SUMIF(ROW(E2:E), "<="&ROW(E2:E), E2:E)))
    

    0 讨论(0)
提交回复
热议问题