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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
erickparra
Frequent Visitor

How to duplicate "Calculated Table"

Hi Gurus!,

 

I need to duplicate a calculated table, where I have maybe 30 calculated columns. I need to create the same table but with little differences (Little changes on DAX). Then I do not want to copy paste all the "code" of columns again to create a new calculated table. Calculated tables are not editables using "Query Editor". Is possible to do that?

 

 

Regards,

6 REPLIES 6
SWegener
Regular Visitor

Hi,

how about the following approach?

 

  1. Create a new calculated table.
  2. Insert the following line into the editor:
    CopyOfMyCalculatedTable = MyCalculatedTable

  3. Adjust the DAX expressions in table CopyOfMyCalculatedTable according to your needs.

 

Greetings

SW

 

Hi,

 

Thanks for your time, but duplicate the same table is not the solution to the given problem.

I mean to create a new indepent table keeping the same formulas for every column based in other calculated table.

 

In other words, to create a new calculated table with several columns for similiar task. I need to copy column by column formulas.

 

Regards,

@erickparra 

 

I think what @SWegener  and @parry2k  were referring to was to use DAX to duplicate the table.

See this example:

Calculated  table.JPG

 

And then the Duplicate:

Duplicate Calculated  table.JPG

 

OR, you can copy the DAX from the Calculated table and alter the output directly in the DAX, as in:

Altered Calculated  table.JPG

 Where I've changed the caculation ouputs in each column

 

If however you need to change the DAX in calculated columns included in a calculated table then I'm out of ideas, except the good old copy and paste.

 

Just out of curiosity, why the need to duplicate a table and alter some DAX? can't you use measures instead?





Did I answer your question? Mark my post as a solution!
In doing so, you are also helping me. Thank you!

Proud to be a Super User!
Paul on Linkedin.






parry2k
Super User
Super User

You have to basically copy your dax expression and make the changes, i don';t think there is a way to duplicate it.

 

Or if possible, create table in power query and then duplicate within power query which you mentioned.



Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!

Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo

If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤


Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.

Hi,

 

Thanks for your time, but is not possible the access to the query editor for calculated tables.

I'm not sure if I can solve the problem with your solution.

 

Regards,

Hi @erickparra , Did you happen to find a solution to copy/paste calculated tables? I need to create few duplicates of a calculated table alongwith their measures and tweak the DAX codes. I agree with you the query editor doesn't show the calculated values. Kindly let me know if you have any updates to this problem. Thanks.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.