I am looking for a formula that will count the number of unique values based on the value of a second column.
For example: column 1 is the house number, column 2 is the type of pet.
House | Pet Type |
1 | dog |
1 | dog |
1 | cat |
2 | dog |
3 | dog |
3 | cat |
In a cell I want to have a formula that gives me the number of homes with dogs. in this case the answer is 3.
In another cell I want to get the number of houses with cats. in this case 2.
Something like: CountUniqueValuesWith(“Dog”, houseRANGE, petRANGE)
I have gone around chasing my tail on this one.
Formula i need is: “Look in column 2 and find all rows with “Dog”. Now take these rows and look in column 1 and return the count of unique house numbers.”
I do not want to use a pivot table for this
thanks all,
bf