Forum Discussion

afrutos's avatar
afrutos
Icon for Resolver I rankResolver I
4 years ago
Solved

Grouping years

Hey guys, what's up?
I have a doubt that I can't solve
I have a table where I am required to put in columns the year, in values the amount and in rows the issuer.

I am asked to show in columns always in such a way: 3 last years from the current date, and the rest a column with the amount of the rest of the years.
so that it would be a column with 2022, 2021, 2020 and another column with the rest of the years.

SOMETHING LIKE THIS

 

  • Hi, afrutos 

    If you have a column 'Year', please try to 'New Group'.

     

    It will add a new column as below:

    You can apply this new field to matrix column.

    Best Regards,
    Community Support Team _ Eason

3 Replies

  • afrutos , Create a new column date/fact table

     

    year new = if(date[year]>= year(today()) -3, "Previous years", Date[Year])

     

    and use this in visual

    • afrutos's avatar
      afrutos
      Icon for Resolver I rankResolver I

      I don't understnd what you mean


      It's not working

      • v-easonf-msft's avatar
        v-easonf-msft
        Icon for Community Support rankCommunity Support

        Hi, afrutos 

        If you have a column 'Year', please try to 'New Group'.

         

        It will add a new column as below:

        You can apply this new field to matrix column.

        Best Regards,
        Community Support Team _ Eason