I have a range F3:H12. In column F, I have students divided into languages groups, Column G names the groups. Column H says how many students are in each group.
Underneath this range I have a list of languages:
I want to replace each language in the table above with a formula which counts the total number of students who speak that language.
="Italian: " & SUMIFS(H3:H12,F3:F12, "Italian"). This works and reads, Italian: 100.
I want to add to the formula so if a language does not feature, like Portuguese, it leaves the cell blank. I have made this formula.
=IF(ISNUMBER(MATCH("Portuguese",F3:F12)),("Portuguese: "&SUMIFS(H3:H12,F3:F12,"Portuguese")), "")
It works in that it counts but still displays, Portuguese: , whether there are entries for Portuguese students or not.
Any ideas on how to fix this would be much appreciated.
Nationality | Group | Number of students |
Italian | Group 1 | 20 |
Italian | Group 2 | 20 |
Italian | Group 3 | 20 |
Italian | Group 4 | 20 |
Italian | Group 5 | 20 |
Arabic | Group 6 | 20 |
Chinese | Group 7 | 20 |
Chinese | Group 8 | 20 |
Spanish | Group 9 | 20 |
|
Underneath this range I have a list of languages:
Italian |
Turkish |
Arabic |
Chinese |
French |
Spanish |
Portuguese |
I want to replace each language in the table above with a formula which counts the total number of students who speak that language.
="Italian: " & SUMIFS(H3:H12,F3:F12, "Italian"). This works and reads, Italian: 100.
I want to add to the formula so if a language does not feature, like Portuguese, it leaves the cell blank. I have made this formula.
=IF(ISNUMBER(MATCH("Portuguese",F3:F12)),("Portuguese: "&SUMIFS(H3:H12,F3:F12,"Portuguese")), "")
It works in that it counts but still displays, Portuguese: , whether there are entries for Portuguese students or not.
Any ideas on how to fix this would be much appreciated.