Search code examples
arraysgoogle-sheetsgoogle-sheets-formulaarray-formulasgoogle-query-language

Exclude 0's from arrayformula


=ArrayFormula({"Test"; query(value(CTA!C2:C)*0.8)})

How would I exclude the rest of the 0's in empty cells?

enter image description here


Solution

  • try:

    =ARRAYFORMULA({"Test"; IFERROR(1/(1/(VALUE(CTA!C2:C)*0.8)))})
    

    or:

    =ARRAYFORMULA({"Test"; QUERY(VALUE(CTA!C2:C)*0.8; "where Col1 <> 0"; )})