• Hi All

    Please note that at the Chandoo.org Forums there is Zero Tolerance to Spam

    Post Spam and you Will Be Deleted as a User

    Hui...

  • When starting a new post, to receive a quicker and more targeted answer, Please include a sample file in the initial post.

Countif

Rik Smith

New Member
Hi Guys,

I have attached a file, i would like to count column D values that are greater than zero, but only if column A or B or C is blank.

Thanks
 

Attachments

  • Excel count.xlsx
    8.8 KB · Views: 2
If you just want the count:
=SUMPRODUCT((((A2:A13="")+(B2:B13="")+(C2:C13=""))>=1)*(D2:D13>0))

If you want the sum:
=SUMPRODUCT((((A2:A13="")+(B2:B13="")+(C2:C13=""))>=1)*(D2:D13>0)*D2:D13)
 
If you just want the count:
=SUMPRODUCT((((A2:A13="")+(B2:B13="")+(C2:C13=""))>=1)*(D2:D13>0))

If you want the sum:
=SUMPRODUCT((((A2:A13="")+(B2:B13="")+(C2:C13=""))>=1)*(D2:D13>0)*D2:D13)



Thanks Luke

That did not work, the answer should be 3, i have highlighted the values that should be counted
 

Attachments

  • Excel count.xlsx
    8.9 KB · Views: 1
Ah. In your first post then, this:
but only if column A or B or C is blank.
should have been:
but only if column A and B and C is blank. Different type of logic, but thankfully easier to do.

=SUMPRODUCT((A2:A13="")*(B2:B13="")*(C2:C13="")*(D2:D13>0))
 
Back
Top