Forum Discussion

Nyx's avatar
Nyx
Frequent Visitor
3 years ago
Solved

Highest value from multiple calculations changing when added to visual

Hi,

 

This is a broad question as my current dataset is very messy.

 

In a measure I sum several columns with 'IF' and use the column that produces the highest value.

I plot this measure on a graph, however upon plotting it the column it draws value from, changes.

This appears to be due to the graphs granularity.

 

I.e. if I sum the column by a year (via a date between slider slicer) to find the highest sum column in that period, the graph plots the measure as months (which I want) and chooses the highest value from any column for each month instead of plotting the value from the column the measure should be choosing based on a year.

If I put the measure to a different visual I can get the sum of the correct column as a return.

 

Is there a way to force the graph to plot the values from the measure without enforcing it's own "per month" filtering?

  • Hi, Nyx 

    According to your description, you want to make your measure without enforcing it's own "per month" filtering?

    The first thing to be clear is that measures are calculated by default based on the current filter context, which is directly related to the fields placed on top of your visuals and the slicer.

    If you want to ignore the month filter, you can use the ALL() function to clear the filter. If you want to keep the slicer filtered, you can use the ALLSELETED() function.

     

    For more infoemation, you can refer to :
    ALLEXCEPT function (DAX) - DAX | Microsoft Learn

    ALL function (DAX) - DAX | Microsoft Learn

     

    Thank you for your time and sharing, and thank you for your support and understanding of PowerBI! 

     

    Best Regards,

    Aniya Zhang

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

     

1 Reply

  • Hi, Nyx 

    According to your description, you want to make your measure without enforcing it's own "per month" filtering?

    The first thing to be clear is that measures are calculated by default based on the current filter context, which is directly related to the fields placed on top of your visuals and the slicer.

    If you want to ignore the month filter, you can use the ALL() function to clear the filter. If you want to keep the slicer filtered, you can use the ALLSELETED() function.

     

    For more infoemation, you can refer to :
    ALLEXCEPT function (DAX) - DAX | Microsoft Learn

    ALL function (DAX) - DAX | Microsoft Learn

     

    Thank you for your time and sharing, and thank you for your support and understanding of PowerBI! 

     

    Best Regards,

    Aniya Zhang

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