Forum Discussion

jppuam's avatar
jppuam
Helper V
4 years ago
Solved

LEFT OUTER JOIN not working

Hello,

i've a table A with the follow:

code_ID    department     costs

1               chemistry        100

2               math                200

3               sociology         300

4               reading            400

 

and a table B with:

code_ID    department     costs

1               chemistry        100

3               sociology         300

 

i want to have a calculatedtable that gives me the data in table A, thats not in table B ?

its the same that i exclude the data in table B that exist in table A.

 

code_ID    department     costs

2               math                200

4               reading            400

 

I've try several functions, but i must be doing some wrong.

 

thanks

JP

 

 

  • If the matching is to be based on all 3 columns:

    NewTable =
    EXCEPT ( Table1, Table2 )

    Regards

9 Replies

  • Hi,

    New query, merge as new:

    You can then delete the final column resulting from this query.

    If the operation is to consider not just the code_ID column then select all columns as required when performing the merge, for example:

    Regards

     

    Regards

    • jppuam's avatar
      jppuam
      Helper V

      I was trying to do it with DAX, i'll try it like you said.

      JP

    • jppuam's avatar
      jppuam
      Helper V

      Jos,

      when i try to merge two query by code, ir gives me this error:

       

      Expression.Error: The 'count' argument is out of range. What is the problem ?

       

      thanks,

      JP

      • Jos_Woolley's avatar
        Jos_Woolley
        Solution Sage

        Hi JP,

        Most likely because you have some rows containing errors prior to the merge. Difficult to be sure without seeing the actual data though, I'm afraid.

        Regards

  • If the matching is to be based on all 3 columns:

    NewTable =
    EXCEPT ( Table1, Table2 )

    Regards

    • jppuam's avatar
      jppuam
      Helper V

      i try that, but i was using a calculated table that i've made and it wasnt working.

      I've change to the original table, an it works....dont understand what was the problem, but its working.

      thanks

      Jos_Woolley