Get instant live expert help with Excel or Google Sheets
“My Excelchat expert helped me in less than 20 minutes, saving me what would have been 5 hours of work!”

Post your problem and you'll get expert help in seconds

Your message must be at least 40 characters
Our professional experts are available now. Your privacy is guaranteed.

Add Cells Based on Blank / Not Blank Criteria

Using Excel SUMIF function you can sum the numbers from a range of cells that meet the criteria based on cells that do not contain any value (Blank) or cells that are contain a value (Not Blank).

While working with data you come across to a situation where you need to sum numbers based on these two criteria. Each of these criteria can be tested on data range or sum_range as per SUMIF syntax.

=SUMIF (range, criteria, sum_range)

In this article, suppose you have a data set of sales orders of various products with their amounts and delivery dates, and some of the dates are missing (Blank) and some are delivery dates are provided (Not Blank) in Delivery Date field.

SUMIF Blank cells

Here, you will learn how to sum numbers based on blank cells criteria. In this example you need to sum Amounts where delivery dates are not mentioned in Delivery Date field. Criterion is supplied as double quotation marks without any space in-between, such as “”.

=SUMIF(D2:D11,"",C2:C11)

This criteria implies to all those cells that contain zero character length, means empty. If a cell contains any space, then it will not meet criteria and it will be considered as Non Blank cell.

This formula will sum all those amounts in range C2:C11 where cells are Blank in range D2:D11.

Here, you can see SUMIF function has sum the numbers (Amount) from range specified as sum_range, where cells in specified range do not contain a value (Delivery Date).

SUMIF Non Blank cells

Using SUMIF function you can sum numbers based on Non blank cells criteria. In our examples, you need to sum Amounts where delivery dates are mentioned in Delivery Date field.

Criteria in SUMIF function is supplied by using one of comparison operators Not Equal to (<>), means not equal to blank, in double quotation marks, such as “<>”.

=SUMIF(D2:D11,"<>",C2:C11)

This formula will sum all those amounts in range C2:C11 where cells are Not Blank in range D2:D11. Criteria implies to all those cells that contain at least one character length, means not empty. If a cell contains even a space, then it will meet criteria and will be considered as Non Blank cell.

SUMIF function will sum the numbers (Amount) in specified sum_range where criteria is met for Non Blank cells in Delivery Date field, specified as range as per syntax.

Did this post not answer your question? Get a solution from connecting with the expert.

Another blog reader asked this question today on Excelchat:

Leave a Comment

avatar

Subscribe to Excelchat.co

Get updates on helpful Excel topics

Subscribe to Excelchat.co

Did this post not answer your question?
Get a solution from connecting with the expert

Another blog reader asked this question today on Excelchat:

Post your problem and you'll get expert help in seconds

Your message must be at least 40 characters
Our professional experts are available now. Your privacy is guaranteed.
Trusted by people who work at
Amazon.com, Inc
Facebook, Inc
Accenture PLC
Siemens AG
Macy's
The Allstate Corporation
United Parcel Service
Dell Inc