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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Helper II
Helper II

Possible to completely replace a table in a model with a newly devloped version of it?

I have an existing data table (built from loading a directory full of Excel files with fairly complicated transformations) that I would like to replace with a completely newly developed version (new table in the same model) - I'd rather not delete the first one as I'd have to redo all of my relationships and measures.  Is there a simple way of doing this? 


Theoretically I could maybe just go into the artifacts and overwrite all the M via the advanced editor, but even if this was possible, it seems that for the main object I want to place, the "Transform Sample File" object seems to have somehow become hidden (which is a big part of the reason I rewrote it from scratch).  It still seems to exist somewhere and continues to execute, but I have no idea how I would get it to reappear.  (But even if it did, I still want to overwrite that tab;e with this new and improved one).

Super User
Super User

If you go into the query editor for your final table, right click > edit query


You should see all the queries present in the .pbix file.  Do you have the transform queries listed there?


I agree that the way to do it is to modify the M code in your final table to use the new source.  If I were you I would add the new source to your model and get it to match the old table EXACTLY (data types, column names, etc) and remember Power Query is case sensitive so you want your column names to be the exact same.

Once you are satisfied you can go into the advanced editor for the new query and copy the code then replace the code for the old query.

That's the thing though, that object seems to have somehow become hidden, I'll show a screenshot:


2019-09-17 09_18_04-BDI - Power Query Editor.jpg

You may notice I've also managed to get inconsistent incremental numbering on some of the different objects within the same folder, perhaps due to messing with filenames thinking I'd make it more obvious what query they are associated with.


I have a feeling I might be screwed?


I don't think you are screwed.  If you can get a table from the new source that matches the old source you can swap in the M code in the advanced editor then delete all the helper queries added by PowerQuery.

The model only knows what comes out of PowerQuery.  As long as the updated output matches the original output the model won't know the difference.

Certainly save a copy of your .pbix to test on though then give it a try.

Helpful resources

Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Monthly Update - June 2024

Check out the June 2024 Power BI update to learn about new features.


Fabric Community Update - June 2024

Get the latest Fabric updates from Build 2024, key Skills Challenge voucher deadlines, top blogs, forum posts, and product ideas.

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

Top Solution Authors