Forum Discussion

ayush_mriti's avatar
ayush_mriti
Helper I
1 year ago
Solved

Filter in DAX calculation

Hi All,

 

This is the Dax calculation and the output. I need to create a Dax calculation which only shows the highlighted column ( Agile-Scrum with 77.42%). In the below calculation I used ALL, so using Filter will now give me the correct %. Please let me know if there is a way to show only the highlighted row by creating new Dax calculation or modify the existing one.

 

Thanks in Advance.

  • If you want the measure to behave the same and just control where it is displayed:

     

     

    IF( 
        ( "Software Delivery", "Agile-Scrum" ) IN 
        SUMMARIZE( 
            'Teams Output Final_Current', 
            'Teams Output Final_Current'[Delivery_Type],
            'Teams Output Final_Current'[Team_Type] 
        ), 
        <YOUR MEASURE>
    )

     

     

     

    And you can alternatively add a slicer, filter to the desired values, then hide the slicer (and disable slicer's interactions with other visuals as needed). per Ashish_Mathur's point, just use the filter pane.

11 Replies

  • Hi Mark, 

    thanks for the calculation, I have change few things to get the desired output.

  • If you want the measure to behave the same and just control where it is displayed:

     

     

    IF( 
        ( "Software Delivery", "Agile-Scrum" ) IN 
        SUMMARIZE( 
            'Teams Output Final_Current', 
            'Teams Output Final_Current'[Delivery_Type],
            'Teams Output Final_Current'[Team_Type] 
        ), 
        <YOUR MEASURE>
    )

     

     

     

    And you can alternatively add a slicer, filter to the desired values, then hide the slicer (and disable slicer's interactions with other visuals as needed). per Ashish_Mathur's point, just use the filter pane.

    • ayush_mriti's avatar
      ayush_mriti
      Helper I

      Hi Mark,

      For some reason its not providing me the correct output. it's showing 100% instead of 77.42%.

  • Hi,

    Why not just expand the filter pane and apply the criteria of Agile Scrum

  • Anonymous's avatar
    Anonymous
    Not applicable

    Thanks for the replies from Ashish_Mathur and MarkLaf.

     

    Hi ayush_mriti ,

     

    Did the current replies resolve your issue? If they were helpful, could you please mark them as solutions? You can also create a new measure and filter the visual according to your needs.

    Measure = IF(MAX('Teams Output Final_Current'[Team_Type])="Agile-Scrum",1,0)

     

    Best Regards,
    Zhu

     

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

    • ayush_mriti's avatar
      ayush_mriti
      Helper I

      Is there a way i can use this filter in calculation instead of filter pane?

  • Hi Ashish,

    I tried using filter pane, but the issue is that,the output of this querry would be the input for another query and using filter pane does not give me exact value i.e 77.42%. That is the reason I was trying to use DAX. Here is the dependent query where % DT needs to be exact 77.42%

    IST = IF([% DT] >= ('Metric Baseline'[2025 Target - %]), "SymbolHigh","SymbolLow")
    • Ashish_Mathur's avatar
      Ashish_Mathur
      Super User

      Hi,

      What is the criteria for extraction?  Should it be the max value in the % DT measure?  Share the download link of the PBI file.

      • ayush_mriti's avatar
        ayush_mriti
        Helper I

        There are 2 extraction/filter criteria:

        1. Delivery_type = "Software Delivery"

        2. Team_type = "Agile-scrum"