Sum Column Only if Another Column is Empty in Google Sheets

google sheets

I am trying to get a sum of column values in a Google Spreadsheet only if there is no value in the adjacent column. Consider the following example:

  A | B
 -------
 40 | 50
 20 | 20
 30 | 
 10 | 

The sum of A should return 40.

I tried to use the following function:

=SUM(FILTER(A:A, ISEMPTY(B:B)))

but all I get is: Error: Unknown function name ISEMPTY. Can anyone tell me what's wrong or how to do it properly?

Best Answer

Replace ISEMPTY with ISBLANK

Your formula should be as follows:-

=SUM(FILTER(A:A, ISBLANK(B:B)))

Now you will get the result as 40