COUNTIF Formula Help - Embed another formula

Copper Contributor

Hi! I have been trying to figure out a formula within a formula, and cannot get it right. I have two sheets, Sheet1 and Sheet 2. On Sheet 1 I have a column of names. Some of the names are duplicated many times. On Sheet2, I have a name column, and a number column. I want to count how many times each name was duplicated on Sheet1. The forumla I have is =COUNTIF(Sheet1!$A$2:$A$20,"John") and it works. However, I have to manually type in the name, example "John" from the name column. Due to how many names I have, I'd like the formula to have another formula embedded that will pull the name from the column to the left, and then lookup and count on sheet1. I hope this makes sense. Thanks for anyone's help!!!

1 Reply

Olá Junebug!

Basta usar a célula de referencia na planilha 2 em vez do valor.

 

=CONT.SE(Planilha1!A:A;Planilha2!A1)

Veja o arquivo em anexo.