Reputation: 21
Thank you so much for looking and helping me out with this.
I am currently using a Countifs() to count the number of long stayers (length of stay) that fall within a certain range. The Countifs() which i have is currently counting the number of cases which fall under the rangers of 1 to 7, 8 to 14, 15 to 21 (No of counts) and so on as seen in the picture below. However, i would need the countifs() to only count the cases under CVM and CTS individually. All the CVM and CTS cases are placed together in 1 single excelsheet,
Code used is : Excel Formula:
=COUNTIFS(N1:N1986, ">=" & G31,N1:N1986, "<=" & H31)
I tried using the below code but its giving me an error message. Excel Formula:
=COUNTIFS(H1:H1986 "=cvm", N1:N1986,">=" & B41,N1:N1986, "<=" & C41)
Column H is where Discipline (CTS/CVM) are located.
I really hope someone would be able to help me out. Thank you so much once again.
Upvotes: 1
Views: 49
Reputation: 8375
So add that constraint for CTS or CVM:
You should check that the cells in column H only contain "CTS" or "CVM" and don't have leading or trailing spaces: " CTS" or "CVM ".
Upvotes: 1