Merging identical tables form multiple databases

  • Merging identical tables form multiple databases

    Posted by Unknown Member on April 15, 2020 at 9:44 am
    • Charles Haight

      Member

      April 15, 2020 at 9:44 AM

      Good morning all,

      I’m trying to take identical tables from 3 separate database instances and merge them together. The challenge is that I want to be able to identify the database (company) each row came from once the data is merged in BI. I’ve tried assigning a company ID in a custom column in each table, but when I append I end up with the company ID I assigned in the primary table in all the appended rows as well. I tried doing a merge new, but even though I say I want all rows from both tables,Ā  it still wants to match on something, and I don’t want to match. I just want to merge multiple identical tables into one table with a custom company id that identifies where each row came from so I can use it in a slicer so the user can see individual company numbers as well as over all corporate numbers.

      Thanks,

      ——————————
      Charlie Haight
      Cedar Springs Technologies
      ——————————

    • Lutz Bendlin

      Member

      April 15, 2020 at 10:55 AM

      You want to use append, not merge .Ā  (NOTE: Technically it doesn’t matter, both result in Table.Combine() )

      ——————————
      Lutz
      ——————————
      ——————————————-

    • Charles Haight

      Member

      April 15, 2020 at 11:32 AM

      Append it what I tried to do before I tried the merge new. Table 1 I added a custom column called Co_Id assigned a value of BRS. Table 2 I did same and assigned a value of FNET. If I append table 2 to table 1, I end up with BRS in all the rows.

      Thanks,

      ——————————
      Charlie Haight
      Cedar Springs Technologies
      ——————————
      ——————————————-

    • Lutz Bendlin

      Member

      April 15, 2020 at 12:40 PM

      Make sure you use the same spelling for the column name. Power Query is case sensitive.

      ——————————
      Lutz
      ——————————
      ——————————————-

    • Ben Howard

      Member

      April 15, 2020 at 3:39 PM

      This works fine for me, please see attached pbix file where I merge two tables as you describe.Ā  As Lutz says, spelling/case might be the problem.

      ——————————
      Ben Howard
      ——————————
      ——————————————-

    Unknown Member replied 5 years, 11 months ago 1 Member · 0 Replies
  • 0 Replies

Sorry, there were no replies found.

The discussion ‘Merging identical tables form multiple databases’ is closed to new replies.

Start of Discussion
0 of 0 replies June 2018
Now

Welcome to our new site!

Here you will find a wealth of information created for peopleĀ  that are on a mission to redefine business models with cloud techinologies, AI, automation, low code / no code applications, data, security & more to compete in the Acceleration Economy!