Forum Discussion
Filtering and Count issues
- 9 years ago
OK, how about this
Count of Records = countrows(TableB)
Count of any type 1 = calculate([count of records],TableB[Type]="1")
Count of any type 2 = calculate([count of records],TableB[Type]="2")
Count only type 1 =SUMX(TableA,if([Count of any type 1] >0 && [Count of any type 2] = 0,1))
Count only type 2 =SUMX(TableA,if([Count of any type 1] =0 && [Count of any type 2] > 0,1))
Count always both =SUMX(TableA,if([Count of any type 1] >0 && [Count of any type 2] > 0,1))
I think you are making this harder than it needs to be :-). Try this
Count of Records = countrows(TableB)
This will count both types
Count of type 1 = calculate([count of records],TableB[Type]="1")
Count of type 2 = calculate([count of records],TableB[Type]="2")
If you want to learn quickly in a structured way, you may like to consider reading my book - I am sure it will help you