Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago
Solved

SumX for specific dates

Hi,

 

I have data loaded in the PowerBi from 2021 to 2026. However, I want the calculations (Sumx and Cumulative) to be done for only 2022 data. I tried using datesbetween with sumx,  but it is calculating just one value- summation for 2022 figures. I am unable to slice it on a monthly basis.

 

For example, in the pic below, I want actuals-2 to start from 27,595,208 and should end at 31st Dec 2022 figure.

 Thank you so much.

  • Anonymous's avatar
    Anonymous
    4 years ago

    I have created a new table by using- calculatetable and datesbetween functions (to filter out only 2022 data).

    Then, I have used this table in my measures to get the desired result.

3 Replies

  • Hi,

    What result are you expecting in the Actuals-2 column?  Please also share the download link of the PBI file.

  • Anonymous's avatar
    Anonymous
    Not applicable

    I have created a new table by using- calculatetable and datesbetween functions (to filter out only 2022 data).

    Then, I have used this table in my measures to get the desired result.