Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
2 years ago
Solved

Target KPI Visual Question

Objective: Create a KPI visual that shows the total email sends for 2024 while the goal and percent change is specific to the 2023 email send total.

 

Problem: The goal and percent change numbers are not populating.

 

Summary: The 511k (2024 email send total) number in my screenshot is accurate. For the KPI visual, the Value = Sum of Sent; Trend axis = Year; Target = Last Year, calculated metric: 

LY = CALCULATE(
    SUM('2024_pbi_vers'[Sent]),
    YEAR('2024_pbi_vers'[Scheduled Date]) = 2023
)

 

Notes: I do also have a date filter on the whole page, limited to 2024 only, as the dataset I'm pulling includes data from past years that I do not want to focus on. Based on my calculated metric, I thought that the KPI visual would compare the 2024 number to the 2023 total but it is not populating. Any ideas as to why this is happening or what I can do to correct this so it does show the 2023 total and the percent change?

 

 

  • Anonymous's avatar
    Anonymous
    2 years ago

    Hi Anonymous 

    You can try the following measure.

    LY =
    CALCULATE (
        SUM ( '2024_pbi_vers'[Sent] ),
        ALLEXCEPT ( '2024_pbi_vers', '2024_pbi_vers'[Scheduled Date] ),
        YEAR ( '2024_pbi_vers'[Scheduled Date] ) = 2023
    )
    

    Best Regards!

    Yolo Zhu

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

3 Replies

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi Anonymous 

    You can try the following measure.

    LY =
    CALCULATE (
        SUM ( '2024_pbi_vers'[Sent] ),
        ALLEXCEPT ( '2024_pbi_vers', '2024_pbi_vers'[Scheduled Date] ),
        YEAR ( '2024_pbi_vers'[Scheduled Date] ) = 2023
    )
    

    Best Regards!

    Yolo Zhu

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

    • Anonymous's avatar
      Anonymous
      Not applicable

      Amazing, this worked perfectly. Thanks.

    • praveen_511's avatar
      praveen_511
      Icon for Advocate I rankAdvocate I

      Try this....

      LY = CALCULATE(
      SUM('2024_pbi_vers'[Sent]),
      FILTER(
      '2024_pbi_vers',
      YEAR('2024_pbi_vers'[Scheduled Date]) = 2023
      )
      )

       

      It should properly retrieve the total email sends for 2023 and help populate your goal and percent change in the KPI visual.