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

Sheets: Index & Match string, search Column, + Countif dates in the future

I am using google sheets, and trying to create a small table that shows me how many events for a single location (city) are currently on sale.

The method I’m using, is trying to search for a string in cell reference "A3" in sheet2 row 2, then count the date values in that column that are in the future.

What I thought would work this way was;
=COUNTIFS(INDEX(MATCH($A3,TestMes!$A2:2,0),TestMes!5:100,0)), ">"&TODAY()

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

I have included an example here that anyone is welcome to edit;
https://docs.google.com/spreadsheets/d/1a2rqWaYNzb2xphnv1RZOoEsKoYBRhJHdJTmIp9EGiSY/edit?usp=sharing

Where;
COUNTIFS counts the number of cells in the range which are greater than today (ie; future)
INDEX is the range of the column where;
MATCH has searched the second row in the second sheet to identify which column to index, then Counts all the dates within that column that are also within the range 5:100,
and finally outputs a count of the current live dates.

I’m getting a formula parse error, have watched 3 20 minute youtube videos, and tried all manner of combinations, im totally stumped.

Am I overcomplicating the formula?

>Solution :

Added formula(s) to your sheet:

=COUNTIF(IFNA(FILTER(Sheet2!$5:$100,Sheet2!$A$2:$2=$A3)),">"&TODAY())

=BYROW(A3:A,LAMBDA(z,IF(z="",,COUNTIF(IFNA(FILTER(Sheet2!5:100,Sheet2!A2:2=z)),">"&TODAY()))))
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