A family of Microsoft spreadsheet software with tools for analyzing, charting, and communicating data.
By using MID() you're returning text, not numbers. One way to return numbers:
=--MID(K95,6,2)
Then your COUNTIF(Z93:Z104,">=4") will work
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Column 1 Col 2
=MID(K95,6,2) 2
=MID(K96,6,2) 3
=MID(K97,6,2) 2
=MID(K100,6,2) 6
=MID(K101,6,2) 6
=MID(K103,6,2) 3
=MID(K104,6,2) 3
=COUNTIF(Z95:Z104,"6") 2
=COUNTIF(Z93:Z104,"">=4) 0
When I use the mid function to extract a no from a cell that contains both txt and nos, whilst I can use then use the countif on the column to count an exact no as 6, I get the correct result, however if I use countif with >=4 as in the second example, I don't. I know the cells in the extracted col 2 are recognized as txt and not nos even though only a no exists, any ideas, why =6 works but >=4 does not?
A family of Microsoft spreadsheet software with tools for analyzing, charting, and communicating data.
Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.
Answer accepted by question author
By using MID() you're returning text, not numbers. One way to return numbers:
=--MID(K95,6,2)
Then your COUNTIF(Z93:Z104,">=4") will work
Answer accepted by question author
any ideas, why =6 works but >=4 does not?
I tested and it sure did not work but I can't answer why. However, as a work around, is practical in your project to modify the formulas with the mid functions like the following and then the countif will work because the cells will contain the numbers as numeric instead of text.
=VALUE(MID(K95,6,2))
This answer has been deleted due to a violation of our Code of Conduct. The answer was manually reported or identified through automated detection before action was taken. Please refer to our Code of Conduct for more information.
Comments have been turned off. Learn more