Reply
Member
Posts: 108
Registered: ‎05-19-2016
Accepted Solution

Copy custom columns created by DAX from one Power Bi file to another Power BI File

Copy custom columns created by DAX from one Power BI file to another Power BI File

 

Hi!

 

I have some files that have tables with custom columns created by DAX. Eg. 5 custom columns.

 

When I create a new file, I can go to the Advanced Editor in Power Query and copy the query to the new file. But it doesn't take the custom columns created by DAX outside Power Query.

 

Is there a way to copy all 5 columns from one file to another instead of copying DAX formulas 5 times and recreate the columns in the new file?

 

Thanks in advance!

 

 


Accepted Solutions
Community Support Team
Posts: 2,522
Registered: ‎02-06-2018

Re: Copy custom columns created by DAX from one Power Bi file to another Power BI File

Hi zapppsr, 

 

In addtion, I would suggest you to export current report to pbit.(Power bi template). Click File-> Export-> Power BI template.

 

Regards,

Jimmy Tao

View solution in original post


All Replies
Super User
Posts: 764
Registered: ‎09-16-2018

Re: Copy custom columns created by DAX from one Power Bi file to another Power BI File

Hi @zapppsr

 

the custom columns added by using DAX do not appear in the Query Editor. Are you able to add them within Power Query instead of DAX?

 

IF you want to reuse the same model within different files you can upload the dataset into Power BI service and then connect live to it via different files as well.



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


Proud to be a Datanaut!

Member
Posts: 108
Registered: ‎05-19-2016

Re: Copy custom columns created by DAX from one Power Bi file to another Power BI File

Hi. Some columns use RELATED() in DAX to improve some features, so they might not be posssible in Power Query, or not practical.

 

But thanks for anwering!

Community Support Team
Posts: 2,522
Registered: ‎02-06-2018

Re: Copy custom columns created by DAX from one Power Bi file to another Power BI File

Hi zapppsr,

 

Power query works on raw table loading, shaping and transformation based in mashup engine. However  DAX works on building of data model based on MDX engine. If you just paste the code in advanced query, you could not get the data model in another pbix file. So I'm afriad you should convert the DAX custom column into power query custom column and try again.

 

Regards,

Jimmy Tao

 

Community Support Team
Posts: 2,522
Registered: ‎02-06-2018

Re: Copy custom columns created by DAX from one Power Bi file to another Power BI File

Hi zapppsr, 

 

In addtion, I would suggest you to export current report to pbit.(Power bi template). Click File-> Export-> Power BI template.

 

Regards,

Jimmy Tao

Highlighted
Member
Posts: 108
Registered: ‎05-19-2016

Re: Copy custom columns created by DAX from one Power Bi file to another Power BI File

Thank you for the suggstions guys!