COUNTIFS to count if data values in Column B are higher than the data values in Column A

Copper Contributor

Hello,

 

Can someone help me with the formula needed to count the number of occurrences, wherein, the data listed in Column B is higher than the data listed in Column A?

 

The answer in the below example would be, 3.

 

Screenshot 2024-03-20 at 3.30.01 PM.png

 

6 Replies

@Mike_D4268 

Your attempt at using the COUNTIFS function is almost correct, but it needs a slight adjustment to work properly. COUNTIFS requires multiple conditions to be specified separately, and you cannot directly compare two ranges like B4:B8>A4:A8 within a single condition. Instead, you can use two separate conditions to achieve your goal. Here's the correct formula:

=COUNTIFS(B4:B8,">"&A4:A8)

This formula will count the number of occurrences where the values in Column B are higher than the corresponding values in Column A within the specified range.

 

My answers are voluntary and without guarantee!

 

Hope this will help you.

 

Was the answer useful? Mark as best response and like it!

This will help all forum participants.

@NikolinoDE 

Thanks NikolinoDE, but that did not work.  That formula populated an array of five different numbers!  I am looking for it to return a single number, 3.

 

Screenshot 2024-03-20 at 4.20.47 PM.png

@Mike_D4268 

=SUMPRODUCT(N(A4:A8<B4:B8))

 

SUMPRODUCT returns the intended result in my sheet.

Thanks OliverScheurich, your SUMPRODUCT formula accomplished my goal. I appreciate it. The user Detlef Lewin's formula also worked.
Thanks Detlet Lewin, your =SUM formula was successful. I appreciate it! The user OliverScheurich provided a formula that also worked...