March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hi Everyone,
I have this line chart. This is the view when I selected June,30,2022 on my date slicer. It shows me results for July 31 2022 and adds up all the data points thus giving me a spike. Unsure as to what mught be causing this. if I have the latest date selected, For example July 12, it gives me correct chart. but if I have a previous date selected it shows me data beyond that date, which is not expected.
The measures used are structured as below
Solved! Go to Solution.
@_Regina , Try if this can work
var _start_date = CALCULATE(MIN('_date unpivot'[Date Key]))
var _end_date = CALCULATE(MAX('_date unpivot'[Date Key]))
var r = CALCULATE(
DISTINCTCOUNT('client'[Client ID]),
filter('transaction', 'transaction'[Processing Date]>= _start_date && 'transaction'[Processing Date] <= _end_date),
'transaction'[Transaction Category] = "Gross Sales"
)
@_Regina , Try if this can work
var _start_date = CALCULATE(MIN('_date unpivot'[Date Key]))
var _end_date = CALCULATE(MAX('_date unpivot'[Date Key]))
var r = CALCULATE(
DISTINCTCOUNT('client'[Client ID]),
filter('transaction', 'transaction'[Processing Date]>= _start_date && 'transaction'[Processing Date] <= _end_date),
'transaction'[Transaction Category] = "Gross Sales"
)
Thank you once again, but why would your solution work and not mine ?
User | Count |
---|---|
21 | |
14 | |
11 | |
8 | |
5 |
User | Count |
---|---|
24 | |
21 | |
20 | |
15 | |
10 |