The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
I have a line chart visual in which i have added a cumulative count measure as mentioned below. I have another page where drill through is enabled. But when I click on certain point for cumulative number line and then do a drill through, then on drill through page it is not showing a data for cumulative number.
Cumulative measure dax -
Var summarytable =
Addcolumns ( Allselected( datetable[dates]),
"K",
Calculate(
Countrows(table1),
Filter (
Allselected(table1), 'table1'[main_date]<=Max(datetable[datess) &&
table1[status] IN {"A","B","C","D"}
)
)
)
Var lastnonzerovalue =
calculate(
Maxx(
Filter(summarytable,[K]>0),
[K]
)
Var x1 =
If(
Isblank(Maxx(summarytable,[K])),
lastnonzerovalue,
Maxx(summarytable, [K])
)
Var b = Date(2023,7,1)
Return
If
(calculate(Isblank(x1),
datetable[dates]>b), 0, x1)
Your measure is malformed. Did you mean to write
Cumulative measure dax =
VAR summarytable =
ADDCOLUMNS (
ALLSELECTED ( datetable[dates] ),
"K",
CALCULATE (
COUNTROWS ( table1 ),
FILTER (
ALLSELECTED ( table1 ),
'table1'[main_date] <= MAX ( datetable[datess] )
&& table1[status] IN { "A", "B", "C", "D" }
)
)
)
VAR lastnonzerovalue =
CALCULATE ( MAXX ( FILTER ( summarytable, [K] > 0 ), [K] ) )
VAR x1 =
IF (
ISBLANK ( MAXX ( summarytable, [K] ) ),
lastnonzerovalue,
MAXX ( summarytable, [K] )
)
VAR b =
DATE ( 2023, 7, 1 )
RETURN
IF ( CALCULATE ( ISBLANK ( x1 ), datetable[dates] > b ), 0, x1 )
Please provide sample data (with sensitive information removed) that covers your issue or question completely, in a usable format (not as a screenshot). Leave out anything not related to the issue.
If you are unsure how to do that please refer to https://community.fabric.microsoft.com/t5/Community-Blog/How-to-provide-sample-data-in-the-Power-BI-...
Please show the expected outcome based on the sample data you provided.
If you want to get answers faster please refer to https://community.fabric.microsoft.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447...
User | Count |
---|---|
26 | |
10 | |
8 | |
6 | |
6 |
User | Count |
---|---|
31 | |
11 | |
10 | |
10 | |
9 |