SOLVED

Power Query - too many lines when concatenating

%3CLINGO-SUB%20id%3D%22lingo-sub-2272554%22%20slang%3D%22en-US%22%3EPower%20Query%20-%20too%20many%20lines%20when%20concatenating%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2272554%22%20slang%3D%22en-US%22%3E%3CP%3EHi%20everyone!%20I've%20just%20started%20using%20PQ%20so%20i'm%20sorry%20if%20this%20is%20a%20dumb%20question.%3C%2FP%3E%3CP%3EI'm%20trying%20analyse%20COVID-19%20data%20in%20my%20state%2C%20in%20Brazil.%20There%20are%20two%20national%20databases%2C%20one%20for%202020%20and%20another%202021%20-%20available%20%3CA%20href%3D%22https%3A%2F%2Fopendatasus.saude.gov.br%2Forganization%2Fministerio-da-saude%22%20target%3D%22_self%22%20rel%3D%22nofollow%20noopener%20noreferrer%22%3Ehere%3C%2FA%3E-%3C%2FP%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fopendatasus.saude.gov.br%2Fdataset%2Fbd-srag-2020%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3ESRAG%202020%20-%20Banco%20de%20Dados%20de%20S%C3%ADndrome%20Respirat%C3%B3ria%20Aguda%20Grave%3C%2FA%3E%3C%2FP%3E%3CP%3E%3CA%20href%3D%22https%3A%2F%2Fopendatasus.saude.gov.br%2Fdataset%2Fbd-srag-2021%22%20target%3D%22_blank%22%20rel%3D%22noopener%20nofollow%20noreferrer%22%3ESRAG%202021%20-%20Banco%20de%20Dados%20de%20S%C3%ADndrome%20Respirat%C3%B3ria%20Aguda%20Grave%3C%2FA%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EUsing%20PQ%20I%20filtered%20data%20only%20about%20my%20state%2C%20and%20combined%20both%20databases.%20However%2C%20there%20is%20something%20going%20wrong.%20There%20are%20two%20problems%3C%2FP%3E%3CP%3E1)%20Excessive%20number%20of%20lines.%3C%2FP%3E%3CP%3E(2020%20filtered%20base)%205096%20lines%20%2B%20(2021%20filtered%20base)%2014684%20%3D%2029368%20%3F%3F%3F%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22pedrofim14_0-1618412107432.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F272828i137566D3B02F4755%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22pedrofim14_0-1618412107432.png%22%20alt%3D%22pedrofim14_0-1618412107432.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSTRONG%3EWhy%20there%20are%20more%20lines%20in%20the%20concatenated%20table%20then%20in%20both%20tables%20together%3F%3C%2FSTRONG%3E%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3E2)%20The%20concatenated%20table%20is%20not%20showing%20part%20of%20the%20data%2C%20as%20I've%20checked%20manually%20with%20the%20filters%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22pedrofim14_1-1618412426922.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F272829iA0BEE45D055861BA%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22pedrofim14_1-1618412426922.png%22%20alt%3D%22pedrofim14_1-1618412426922.png%22%20%2F%3E%3C%2FSPAN%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22pedrofim14_2-1618412455683.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F272831iA0D1C0B639B39212%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22pedrofim14_2-1618412455683.png%22%20alt%3D%22pedrofim14_2-1618412455683.png%22%20%2F%3E%3C%2FSPAN%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22pedrofim14_2-1618412455683.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3CIMG%20src%3D%22https%3A%2F%2Ftechcommunity.microsoft.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F272831iA0D1C0B639B39212%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22pedrofim14_2-1618412455683.png%22%20alt%3D%22pedrofim14_2-1618412455683.png%22%20%2F%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E2021%20table%5E%26nbsp%3B%20(1st%20pic)%20%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%26nbsp%3B%20Concatenated%20table%5E(2nd%20pic)%3C%2FP%3E%3CP%3E%26nbsp%3B%3C%2FP%3E%3CP%3EI'm%20using%20Microsoft%20365%20for%20Business%3C%2FP%3E%3CP%3E%3CSTRONG%3EWhat%20can%20I%20do%20to%20solve%20those%202%20problems%3F%3C%2FSTRONG%3E%20Thank%20you%20very%20much!%3C%2FP%3E%3C%2FLINGO-BODY%3E%3CLINGO-LABS%20id%3D%22lingo-labs-2272554%22%20slang%3D%22en-US%22%3E%3CLINGO-LABEL%3EExcel%3C%2FLINGO-LABEL%3E%3C%2FLINGO-LABS%3E
New Contributor

Hi everyone! I've just started using PQ so i'm sorry if this is a dumb question.

I'm trying analyse COVID-19 data in my state, in Brazil. There are two national databases, one for 2020 and another 2021 - available here-

SRAG 2020 - Banco de Dados de Síndrome Respiratória Aguda Grave

SRAG 2021 - Banco de Dados de Síndrome Respiratória Aguda Grave

 

Using PQ I filtered data only about my state, and combined both databases. However, there is something going wrong. There are two problems

1) Excessive number of lines.

(2020 filtered base) 5096 lines + (2021 filtered base) 14684 = 29368 ???

pedrofim14_0-1618412107432.png

Why are there more lines in the concatenated table then in both tables together?

 

2) The concatenated table is not showing part of the data, as I've checked manually with the filters

pedrofim14_1-1618412426922.pngpedrofim14_2-1618412455683.png

2021 table^  (1st pic)                                    Concatenated table^(2nd pic)

 

I'm using Microsoft 365 for Business

What can I do to solve those 2 problems? Thank you very much!

3 Replies
best response confirmed by pedrofim14 (New Contributor)
Solution

@pedrofim14 It seems like you are appending the 2020 data to itself. 14684 X 2 = 29368

@pedrofim14 

I agree with @Riny_van_Eekelen , but it's better if you share the file to be sure. These days there tons of files working with COVID data, I don't think in this one is something unique what's worth to protect, especially initial version.

@Sergei Baklan @Riny_van_Eekelen you were precisely right! I've corrected it and both problems are now solved. Thank you very much for your attention!
I'll leave the database here anyway, as Sergei suggested: https://observatoriosocialmt-my.sharepoint.com/:f:/g/personal/pedro_fim_observatoriosocialmt_org/Epi...