Forum Discussion

blackbach2728's avatar
blackbach2728
New Member
2 years ago
Solved

Compare data from two different table visuals that exist from different data sources

I have two table visuals that I have created in a dashboard in two seperate pages. This data is from two different data sources that I connected to by direct query. I need a count of how many records...
  • Anonymous's avatar
    Anonymous
    1 year ago

    Hi blackbach2728 

     

    Please try this:
    Here are 2 sample data:

    Table A:

    Table B:

    Click Transform data in the Home pane to use power query.

    Click Custom Column in the Add Column pane:

     

    You can use this m-code to get numbers from columns:

    Text.Select([Value],{"0".."9","."})

    Add for both 2 tables:

    Close&Apply.

    Finally, add a measure:

    MEASURE =
    COUNTROWS (
        FILTER (
            CROSSJOIN ( 'Table A', 'Table B' ),
            'Table A'[Custom] = 'Table B'[Custom]
        )
    )
    

    The result is as follow:

     

     

    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.