Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
3 years ago
Solved

undefined

Hi i have table with column rank, i need to filter Rank1 and Ran2 and i need to sum the rank1 + rank 2 how can i do it. Here is sample data screen shot for your reference  
  • Anonymous's avatar
    Anonymous
    3 years ago

    Hi Anonymous ,

    Pleasetry below steps:

    1. below is my test table

    Table:

    2. create a measure with below dax formula

    Measure =
    VAR str =
        CONCATENATEX ( 'Table', [Rank], "," )
    VAR tmp =
        FILTER ( ALL ( 'Table' ), CONTAINSSTRING ( str, 'Table'[Rank] ) )
    VAR _val =
        SUMX ( tmp, [Value] )
    RETURN
        IF ( ISFILTERED ( 'Table'[Rank] ), _val )
    

    3. add a table visual with fileds, add a slicer with field, add a card visual with measure

    Please refer the attached .pbix file.

     

    Best regards,
    Community Support Team_Binbin Yu
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.