Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Copy column from one table to another table

Hi,

 

I am trying to copy the value from a column (self) from a table called GetIssues to another table called 49407.

I created a new column called Self in 40407 and I tried to use LOOKUPVALUE but I am not able to copy the information from one table to the other one. 

Thanks in advance 

 

  • Hi Anonymous ,

     

    One sample for your reference, please check the following steps as below.

     

    1. Insert index column in both table in power query.

    2. Close and apply, then we use the LOOKUPVALUE to get the excepted result.

    Self in 40407 = LOOKUPVALUE(GetIssues[Self],GetIssues[Index],'49407'[Index])

     

    For more details, please check the pbix as attached.

     

     

     

  • Hi Anonymous ,

     

     

    merge This should help you.

     

    If this solves your issues, please mark it as the solution, so that others can find it easily. Kudos are nice too.
    Nathaniel

8 Replies

  • v-frfei-msft's avatar
    v-frfei-msft
    Community Support

    Hi Anonymous ,

     

    One sample for your reference, please check the following steps as below.

     

    1. Insert index column in both table in power query.

    2. Close and apply, then we use the LOOKUPVALUE to get the excepted result.

    Self in 40407 = LOOKUPVALUE(GetIssues[Self],GetIssues[Index],'49407'[Index])

     

    For more details, please check the pbix as attached.

     

     

     

    • Anonymous's avatar
      Anonymous
      Not applicable

      Thanks, it works, but I am looking to get all the rows from GetIssues [self], in the 49407.

      In 49407 there are only 3 rows but I need all the rows from GetIssues [self].

      Is there any way to have all the rows?

      Thanks in advance

      • Anonymous's avatar
        Anonymous
        Not applicable

        Quick question that it might resolve my issue.

        How can I create a new table in the query editor and add a column using the LOOKUPVALUE as mentioned before?

        I am looking to create a new table and copy all the information from GetIssues[Self] to a new table with a new column.

        Thanks in advance for your help 

  • hello Anonymous 

    You will have to share the structure of the tables and what field(s) they have in common.  A sample of both tables in a format we can copy and paste (not a screen shot) would be helpful as well.  You can copy from excel and paste directly into a post.

  • Nathaniel_C's avatar
    Nathaniel_C
    Community Champion

    Hi Anonymous ,

    You can look at my post here, on merge...merge post

     

    If this solves your issues, please mark it as the solution, so that others can find it easily. Kudos are nice too.
    Nathaniel

  • Joan_Wanjiru_'s avatar
    Joan_Wanjiru_
    Frequent Visitor

    Add index columns in both tables then merge the tables using the two index columns. or if the data source is excel you can copy from excel and paste into your table in power query.

  • Anonymous's avatar
    Anonymous
    Not applicable

    How to do this in Power Query ( Without using append or merging & DAX?)