Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
Hi All,
In a card visual, I have used a measure which takes the distinct count of product no. Now in additional to that, I have to include a logic to get the distinct count of product no where Actuals + Forecast > 0. In the below example, the distinct count of product no where Actuals + Forecast > 0 is 4. This logic I need to achieve in a Card visual. Can anybody help me with the logic here?
Product No | Actuals | Forecast |
1 | 0 | 30 |
2 | 0 | 0 |
3 | 65 | 100 |
4 | 50 | 0 |
5 | 0 | 0 |
6 | 100 | 150 |
Thanks in advance!!
Solved! Go to Solution.
HI @MadhumithaV_26,
I'd like to suggest you extract the 'product no' field values based on filter conditions, then you can use countrows function with these field values to get the count.
formula =
CALCULATE (
COUNTROWS ( VALUES ( Table[Product No] ) ),
FILTER ( ALLSELECTED ( Table ), [Actual] + [Forecast] > 0 )
)
Regards,
Xiaoxin Sheng
HI @MadhumithaV_26,
I'd like to suggest you extract the 'product no' field values based on filter conditions, then you can use countrows function with these field values to get the count.
formula =
CALCULATE (
COUNTROWS ( VALUES ( Table[Product No] ) ),
FILTER ( ALLSELECTED ( Table ), [Actual] + [Forecast] > 0 )
)
Regards,
Xiaoxin Sheng
User | Count |
---|---|
42 | |
28 | |
23 | |
18 | |
16 |
User | Count |
---|---|
54 | |
35 | |
18 | |
18 | |
15 |