COUNTIF greater than 0 in one column and unique values in another

RodneyC

Active Member
Joined
Nov 4, 2021
Messages
278
Office Version
  1. 2016
Platform
  1. Windows
I need a formula for a cell in a tab named SnapShot that will

1. Count once for everything in X3:X780 in a tab named Data where the value is greater than 0 and
2. Count once in the Data tab, $G$3:$G$780 is a unique entry.

Said another way, if there are 12 entries in column X where the value is greater than 0 but in column G, there are only four unique entries where the value is X is greater than 0, the result will be 4. I will carry this formula over to another column where I'm evaluating Y3:Y780 instead of X. $G$3:$G$780 will remain constant.

Thanks in advance
 

Excel Facts

Which Excel functions can ignore hidden rows?
The SUBTOTAL and AGGREGATE functions ignore hidden rows. AGGREGATE can also exclude error cells and more.
Do you mean "unique" or "unique distinct"?
If "Green" is showing 27 times in column G, Red is showing 12 times and orange is showing 6 times, the formula would report 3 because there are three different values. This statement assumes that at least one value in X for green, red and orange was greater than 0. If there were no values in X greater than 0 where the value in G was red, the formula would show 2, one for green and another for orange. Green, red and orange are simply sample values and have no relation to what the actual values in G might be. There could be hundreds of different values.
 
Upvote 0

Forum statistics

Threads
1,215,593
Messages
6,125,716
Members
449,254
Latest member
Eva146

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top