Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.
My dataset has 371 rows in it. A table that I created and filtered shows 103 rows. After adding the appropriate columns, I have different counts for my data categories such as A = 1, B = 2, C = 10, D = 0, etc. How do I create a measure that shows the total count of the table data, 103? The goal is to find the percentage of A, B, C, D, etc.
Solved! Go to Solution.
@Anonymous
try
CALCULATE( COUNTROWS('Table'), ALL('Table'), 'Table'[Period] <> "Future")
hi @Anonymous
Please try this:
Denominator = CALCULATE( COUNTROWS('Table'), FILTER(ALL('Table'),'Table'[Period] <> "Future"))
or
Denominator = CALCULATE( COUNTROWS('Table'), FILTER(ALLSELECTED('Table'),'Table'[Period] <> "Future"))
Regards,
Lin
Hi @Anonymous
try smth like
Measure = DIVIDE(
CALCULATE(COUNTROWS(Table), ALLEXCEPT(Table, Table[Category]) ),
CALCULATE(COUNTROWS(Table))
)
Thanks for replying, @az38 . Can you help me with the measure for just the denominator? My dataset has a column for Period which has the possible values of "Future", "Current Month", and "Last 11 Months". I want to set the denominator equal to the number of rows where the Period equals "Current Month" OR "Past 11 Months", or to put another way where Period is NOT equal to "Future".
I tried the formula Denominator = CALCULATE( COUNTROWS('Table'), ALLEXCEPT ('Table'[Period] <> "Future")) but that returned a syntax error.
hi @Anonymous
Please try this:
Denominator = CALCULATE( COUNTROWS('Table'), FILTER(ALL('Table'),'Table'[Period] <> "Future"))
or
Denominator = CALCULATE( COUNTROWS('Table'), FILTER(ALLSELECTED('Table'),'Table'[Period] <> "Future"))
Regards,
Lin
@Anonymous
try
CALCULATE( COUNTROWS('Table'), ALL('Table'), 'Table'[Period] <> "Future")
User | Count |
---|---|
101 | |
90 | |
80 | |
71 | |
70 |
User | Count |
---|---|
114 | |
98 | |
97 | |
73 | |
72 |