Forum Discussion

patator35's avatar
patator35
Frequent Visitor
8 years ago
Solved

Update table based on values from other table ?

Hello
I have a table A containing customer numbers and other columns (10000 + entries)
I have a table B containing customer numbers and one column containing a country code (10 rows)

How can I update one column of Table A with country codes coming from table B where customer codes are the same ?
Thanks
  • patator35

     

    Do you mean Update  an exisitng column?

     

    If the 2 tables are related, You can simply use RELATED(TableB[Country Codes)) to get CountryCodes in TableA

    or use LOOKUPVALUE if they are not related

2 Replies

  • Zubair_Muhammad's avatar
    Zubair_Muhammad
    Community Champion

    patator35

     

    Do you mean Update  an exisitng column?

     

    If the 2 tables are related, You can simply use RELATED(TableB[Country Codes)) to get CountryCodes in TableA

    or use LOOKUPVALUE if they are not related

    • patator35's avatar
      patator35
      Frequent Visitor
      Yes i mean update only values of an existing column of table A where customer code is the same than in table B. Yes both tables are relate thanks to the customer nb Column existing in both tables.