Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
2 years ago

Show Only Matching Values

Hi 

 

Can someone help me on how to create a measure or m-code in showing only values that matched the Invoice Number for the fak column and don't display the rest?

 

//NT

 

 

12 Replies

  • Hi,

     

    You can create a measure as below by replacing with your columns:

     

    Matches = IF(CALCULATE(SUM('Table'[A]))=CALCULATE(SUM('Table'[Invoice])),1,0)
     
    Then, put the measure into the filter pane of the table visual and have it set to 1
     

     

  • Hi Anonymous 

    Create a measure like this:

    Same day payment =
     If(
        SELECTEDVALUE(Sales[Invoice Number]) = SELECTEDVALUE(Sales[faktuurnr]) --Change to your tablename
        ,1
        ,0
     )
    Add it into the filter pane of your visual and filter to 1:

     

  • Anonymous's avatar
    Anonymous
    Not applicable

    thanks for the fast assistance. is it possible not to use the filter pane but shows blanks for rows that don't match so i can see the whole sheet?

    • SamWiseOwl's avatar
      SamWiseOwl
      Super User

       If(

          SELECTEDVALUE(Sales[Invoice Number]) = SELECTEDVALUE(Sales[faktuurnr]) --Change to your tablename

          ,"Match"

          ," "

       )

      Something like that?

      • Anonymous's avatar
        Anonymous
        Not applicable

        I add the measure in the table but no colum is being created as shown. am i doing something wrong?

         

         

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi Anonymous 

     

    Have you solved your problem? If so, can you share your solution here and mark the correct answer as a standard answer to help other members find it faster?

    If not, could you please share your data(exclude sensitive data), or create some sample data, and your target outcome, so that we can help you better.

    Thank you very much for your kind cooperation.

     

    Best Regards

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