cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
wi11iamr
Advocate II
Advocate II

Append Query duplicates some columns

Hi there,

 

I have two identical tables (daya from FY2016 and FY2017) and am using an Append Query to merge them into a new combined table.

 

Using the Append Query function, there are 4 columns which are duplicated at the end of my new table. Having read up on this it's my understanding that this happens when the columns in the 2nd tabel have no match in the first table, and they are then added as new columns to the combined table.

 

Here's the kicker - I have checked (and triple checked) that the column names and data types are exactly the same. Of my ~40 columns, only these 4 give me a problem.

 

Any suggestions on where I could go and dig a little deeper to uncover my problem?

 

Thanks

William R.

 

1 ACCEPTED SOLUTION
wi11iamr
Advocate II
Advocate II

Oh my word...!!!

 

So, before I basj myself over the head, let me share my mistake with you...

 

The issue was quite definitely different column names - there were some trailing spaces in the names of the 4 columns in my 2nd table. I had however checked for this earlier, within Excel, using a pattern match to identify any spelling differences, howeve it appears that the Excel pattern match excluded trailing spaces, and thus did not alert me to the fact that the column names were in fact not the same.

 

Ah well, thanks for listening... 😉

View solution in original post

5 REPLIES 5
hourir2
Frequent Visitor

Thanks for this, helped me out!!

 

wi11iamr
Advocate II
Advocate II

Oh my word...!!!

 

So, before I basj myself over the head, let me share my mistake with you...

 

The issue was quite definitely different column names - there were some trailing spaces in the names of the 4 columns in my 2nd table. I had however checked for this earlier, within Excel, using a pattern match to identify any spelling differences, howeve it appears that the Excel pattern match excluded trailing spaces, and thus did not alert me to the fact that the column names were in fact not the same.

 

Ah well, thanks for listening... 😉

Thank you, your post saved me from giving up.  

Don't beat yourself up too badly. I'd been trying to figure this out for a few hours and your post put me on the road to a sloution. I have no idea where the extra spaces originate but the result is a rather annoying and time consuming piece of debugging. Thanks again. 

jpt1228
Responsive Resident
Responsive Resident

Thanks for this - I ran into the same thing and couldnt figure out why. The table had a space after the last letter of the column name. All fixed! 

Helpful resources

Announcements
August 2022 update 768x460.jpg

Check it Out!

Click here to learn more about the August 2022 updates!

August 1 episode 9_no_dates 768x460.jpg

The Power BI Community Show

Watch the playback when Priya Sathy and Charles Webb discuss Datamarts! Kelly also shares Power BI Community updates.

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Top Solution Authors
Top Kudoed Authors