Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
4 years ago
Solved

How to avoid MONTH filter in table -

Hi Team

 

Below is the snapshot of my data

 

And below is the table I have genrated in PowerBI

 

Full Year Sales =
CALCULATE(SUM(Sales[SALES]),
FILTER(Sales,Sales[YEAR]=SELECTEDVALUE(Sales[YEAR])))

 

What I am trying - I am creating a measure - FUL YEAR Budget - in which if any user selectes any month irrespective of any year - that measure must not change the value of sales - when I am clicking any month - it is filtering sales according to that month - it should be showing the total sales for selected years - whether 1 year is selected or 2 or more... Kindly help me please

 

Thanks and regards

RatanB

  • Anonymous's avatar
    Anonymous
    4 years ago
    Full Year Sales =
    CALCULATE(SUM(Sales[SALES]),
    REMOVEFILTERS(Sales[MONTH]))
     
    Above was the solution I tried and it worked like charm. Thanks for your help.

9 Replies

  • ERD's avatar
    ERD
    Community Champion

    Hi Anonymous ,

    Just choose this particular slicer not to filter your table:

    • click on the slicer
    • choose Format tab
    • click Edit iteractions
    • hover over the table
    • choose None option

    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

      Hi Thanks for you reply.. But problem is I have other visuals also on which I dont want this to be impacted, thats why I am looking where a mesaure could be created which would not have any impact incase any month filter is selected.

      • ERD's avatar
        ERD
        Community Champion
        • You can edit iteraction for each visual
        • In case of a measure, you can use ,ALL(T[MONTH]) modifier in your CALCULATE

         

        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

      I have tried this also. but still when I am selecting months, measure is changing and showing values for months only. not for years

  • Anonymous's avatar
    Anonymous
    Not applicable
    Full Year Sales =
    CALCULATE(SUM(Sales[SALES]),
    REMOVEFILTERS(Sales[MONTH]))
     
    Above was the solution I tried and it worked like charm. Thanks for your help.