Follow

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use
Contact

Countif count Sunday to Friday correctly until it reach Saturday in google sheets

I have 14 dates which only 1 fall on a Saturday. I like to count that Saturday and use it in another formula.

=ArrayFormula(COUNTIF((WEEKDAY(D5:D31,1)),"=7"))

However, the answers I get from the formula is 14 and not 1.
True holiday counter

MEDevel.com: Open-source for Healthcare and Education

Collecting and validating open-source software for healthcare, education, enterprise, development, medical imaging, medical records, and digital pathology.

Visit Medevel

>Solution :

You can try

=arrayformula(countif(MAP(tocol(B5:B,1),LAMBDA(a,weekday(a))),"=7"))

Add a comment

Leave a Reply

Keep Up to Date with the Most Important News

By pressing the Subscribe button, you confirm that you have read and are agreeing to our Privacy Policy and Terms of Use

Discover more from Dev solutions

Subscribe now to keep reading and get access to the full archive.

Continue reading