Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
Hi,
I tried the following DAX formula to calculate the cumulative quantity, but the values to remain the same in "Quantity Running". In 2nd row it should be 135 (125 + 10).
There is a relationship between Date[Date] and Salesorderdetail[requestdeliveryby].
Thanks.
Solved! Go to Solution.
Your dax should correct if you are creating a measure. If you want a calculated column, it should be:
Columns = calculate(sum[quantity]),filter(date, [date]<=earlier[date]))
Paul Zheng _ Community Support Team
If this post helps, please Accept it as the solution to help the other members find it more quickly.
Hi,
Assuming the Date column in the visual has been dragged from the Date Table, write these measures:
Quantity sold = sum(salesorderdetail[Quantity])
Quantity sold YTD = calculate([Quantity sold],datesytd(calendar[date),"31/12")
Hope this helps.
Your dax should correct if you are creating a measure. If you want a calculated column, it should be:
Columns = calculate(sum[quantity]),filter(date, [date]<=earlier[date]))
Paul Zheng _ Community Support Team
If this post helps, please Accept it as the solution to help the other members find it more quickly.
Try this
Quntity Running : =
VAR MaxDate = MAX ( 'Date'[Date] ) -- Saves the last visible date
RETURN
CALCULATE (
[Quantity], -- Computes sales amount
'Date'[Date] <= MaxDate, -- Where date is before the last visible date
ALL ( Date ) -- Removes any other filters from Date
)
Still same result:
I think you doing something wrong- check again
send me your file if possible
User | Count |
---|---|
140 | |
113 | |
104 | |
77 | |
65 |
User | Count |
---|---|
136 | |
118 | |
101 | |
71 | |
61 |