Solved

# Excel checking if teams have appeared in previous yeas

Posted on 2013-01-22
168 Views
Hi all,
I wanted to check if the teams this year have played in all the five previous years. I've attached a spreadsheet to show you what I've done. What I'm doing isn't working which is why I'm asking for help. I've used the function below.

=SUMPRODUCT(--('7-8'!\$D\$2:\$D\$307=B2),--('8-9'!\$D\$2:\$D\$307=B2),--('9-10'!\$D\$2:\$D\$307=B2),--('10-11'!\$D\$2:\$D\$307=B2),--('11-12'!\$D\$2:\$D\$307=B2))

B2 would be the team names cell.

The thing is that I had it working only for the bottom 3 teams at one stage but I know there are more teams that qualify.

Regards to all.
Dave
Team-count-over-the-previous-5-y.xls
0
Question by:Irazor

LVL 23

Accepted Solution

NBVC earned 250 total points
ID: 38807500
You can use:

=COUNTIF('7-8'!\$D\$2:\$D\$307,B2)+COUNTIF('8-9'!\$D\$2:\$D\$307,B2)+COUNTIF('9-10'!\$D\$2:\$D\$307,B2)+COUNTIF('10-11'!\$D\$2:\$D\$307,B2)+COUNTIF('11-12'!\$D\$2:\$D\$307,B2)

This counts the number of time the name appears in all the sheets.

If you want to simply count if they appear at least once in any sheet, then you can add >0 to each countif

e.g

=(COUNTIF('7-8'!\$D\$2:\$D\$307,B2)>0)+(COUNTIF('8-9'!\$D\$2:\$D\$307,B2)>0)+(COUNTIF('9-10'!\$D\$2:\$D\$307,B2)>0)+(COUNTIF('10-11'!\$D\$2:\$D\$307,B2)>0)+(COUNTIF('11-12'!\$D\$2:\$D\$307,B2)>0)

This will tell you how many of the 5 sheets the name appears in.
0

Author Closing Comment

ID: 38807515
Excellent this is exactly what I wanted. Thanks NB_VC.
0

## Featured Post

### Suggested Solutions

How to quickly and accurately populate Word documents with Excel data, charts and images (including Automated Bookmark generation) David Miller (dlmille) Synopsis In this article you’ll learn how to use ExcelToWord! to copy data,charts, shapes …
This tutorial explains how to create a series of drop-down lists that are dependent upon prior selections to guide (“force”) the user to make the correct selection and reduce data errors within Microsoft Excel. Excel 2010 was used for this tutorial;…
This Micro Tutorial demonstrate the bugs in Microsoft Excel for Mac with Pivot Charts.
This Micro Tutorial will demonstrate how to use longer labels with horizontal bar charts instead of the vertical column chart.