• 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 and Countifs error

David Cerny

New Member
I am trying to count concurrent users, but both COUNTIF and COUNTIFS are not calculating properly at (what seems like) random rows.

My COUNTIFS formula (in Column C) of'
=COUNTIFS($A$5:$A$10,"<="&A7,$B$5:$B$10,">="&A7)
is not working in Row 7 only.

I also tried COUNTIF formula (in Column D)of;
=COUNTIF($A$5:$A$10,"<="&A7)
which should count all Logins <= Row 7, but the result is only 2 (since Column A is sorted by time, Column D should increment by 1 each row)

upload_2017-2-20_15-38-12.png

For some reason, SUMPRODUCT works, but I need to convey this calculation to a web designer and the count functions are easier to understand.

I have uploaded the file for your help.

If anyone can help me out, it would be greatly appreciated.

David
 

Attachments

  • Countifs error example (2017-02-20).xlsx
    11.2 KB · Views: 3
Hi:

I have used the formula as attached, is this what you are looking for?

Note: formulas in yellow cells
Thanks
 

Attachments

  • Countifs error example (2017-02-20).xlsx
    11.4 KB · Views: 4
Nebu,
Thank you, your formula works great (I do not fully understand it, but I can live with that).
Do you know why the COUNTIF(S) formulas were not working? It was randomly determining that a login time was not = to itself. I do need to convey the calculation to a programmer and COUNTIF(S) are easier to explain (when they work).

Thank you again,
David
 
Hi:

I think it is something to do with array , the mmult in my formula is basically an array. I guess you were getting an error because you were using an non-array formula.

Thanks
 
Back
Top