Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Append several SharePoint list sources. How to do it in M?

Hello everyone!

 

I want to merge several SharePoint lists (around 100), with the same column names, but with different names and in different sites.

 

I already tried to bring all tables and then append, but would be terrible to do it in a hundred sources. Is there a easier way to get these data in a single M Code?

1 ACCEPTED SOLUTION
Greg_Deckler
Community Champion
Community Champion

Yes you can, I wrote a blog article on this once. Basically all you have to do is something like:

 

let

  Source = ...

  Source1 = ...

  Source2 = ...

  Final = Table.Combine({Source, Source1, Source2})

in

  Final



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

View solution in original post

4 REPLIES 4
Greg_Deckler
Community Champion
Community Champion

Yes you can, I wrote a blog article on this once. Basically all you have to do is something like:

 

let

  Source = ...

  Source1 = ...

  Source2 = ...

  Final = Table.Combine({Source, Source1, Source2})

in

  Final



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Hi Greg,

Thank you for code.  amazing.  How do I get a source sublist name for each row?

 

Elizabeth Tachjian
Anonymous
Not applicable

Thanks,

 

Is it possible to do like a For function? Because I have a list of links in SP and now I realized we have 620 SP lists and this number increases +120 yearly.

 

 

 

let

  Source = List_of_SP_List_Links

 

For each List_of_SP_List_Links

do  Final = Table.Combine({Final, SharePoint.Tables(List_of_SP_List_Links)})

next

in

  Final

Hi @Anonymous ,

 

If you have a list  of SP links, you can import that as a table and add a custom column like this one:

 = SharePoint.Tables([URL Column], [ApiVersion = 15])

And work from t here.





Dane Belarmino | Microsoft MVP | Proud to be a Super User!

Did I answer your question? Mark my post as a solution!


"Tell me and I’ll forget; show me and I may remember; involve me and I’ll understand."
Need Power BI consultation, get in touch with me on LinkedIn or hire me on UpWork.
Learn with me on YouTube @DAXJutsu or follow my page on Facebook @DAXJutsuPBI.

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.