Forum Discussion
oitp
6 years agoHelper I
Sum latest values based on date (duplicate dates)
Hi, I have a table as the table describes. I want to sum the values that has the latest UpdatedDate. So if we keep the table as an example I want to sum the three rows with the UpdatedDate 2019-12-15 01:05:36.
How can I do this? When I try the measure below I only get an error saying that "A date column containing multiple dates was specified in the call to function 'LASTDATE'. This is not supported"
Measure: CALCULATE(SUM(Counter);LASTDATE(UpdatedDate)
| Updated Date | Counter |
| 2019-12-15 01:05:36 | 46540 |
| 2019-12-15 01:05:36 | 5249 |
| 2019-12-15 01:05:36 | 51789 |
| 2019-11-25 11:23:09 | 44517 |
| 2019-11-25 11:23:09 | 4980 |
| 2019-11-25 11:23:09 | 49497 |