Microsoft Fabric Community Conference 2025, March 31 - April 2, Las Vegas, Nevada. Use code FABINSIDER for a $400 discount.
Register nowThe Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.
Hi Everyone, I'm exploring the TMDL view and checked the displayfolder function which is super helpful to change folder of multiple measures at a single time, but i'm unable to figure out how we can change the source table of measures using TMDL view. Is there any function or command using which we can change source table of measure using TMDL view
Solved! Go to Solution.
Hi,@anmolmalviya05 .I am glad to help you.
This is my test:
Unfortunately, for the time being, I have not been able to find a command in TMDL View to batch modify the original form names of multiple measures.
I used the createOrReplace command to modify the information for a single measure (created a new measure and renamed it)
In the officially provided documentation, there is currently only the createOrReplace command.
TMDL scripts | Microsoft Learn
Maybe you could achieve a similar effect in other ways: batch change the source table name of the measure to realize the move of the measure to other tables for management.
URL:
Solved: How to move measure from folder to out of folder ? - Microsoft Fabric Community
Or use the modify command in DAX VIEW
The approach is as follows:
Prepare code in Excel: write repetitive DAX code in Excel. Example:
DEFINE
MEASURE 'table'[Measure1] = SUM('Fact_Sales'[quantity])
MEASURE 'table'[Measure2] = SUM('Fact_Sales'[amount])
...
MEASURE 'table'[MeasureN] = SUM('Fact_Sales'[value])
Copy and Paste to DAX Query View window: copy the code from Excel and paste it into Power BI's DAX Query Window. Perform Unified Processing.
I hope my suggestions give you good ideas, if you have any more questions, please clarify in a follow-up reply.
Best Regards,
Carson Jian,
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi,@anmolmalviya05 .May I ask if you have found the relevant command or code later?
If your problems have been solved correctly (or other ways have been used as alternatives), you can share them. Thank you for your support of Power BI. Good luck with your work.
Best Regards,
Carson Jian
Hi,@anmolmalviya05 .I am glad to help you.
This is my test:
Unfortunately, for the time being, I have not been able to find a command in TMDL View to batch modify the original form names of multiple measures.
I used the createOrReplace command to modify the information for a single measure (created a new measure and renamed it)
In the officially provided documentation, there is currently only the createOrReplace command.
TMDL scripts | Microsoft Learn
Maybe you could achieve a similar effect in other ways: batch change the source table name of the measure to realize the move of the measure to other tables for management.
URL:
Solved: How to move measure from folder to out of folder ? - Microsoft Fabric Community
Or use the modify command in DAX VIEW
The approach is as follows:
Prepare code in Excel: write repetitive DAX code in Excel. Example:
DEFINE
MEASURE 'table'[Measure1] = SUM('Fact_Sales'[quantity])
MEASURE 'table'[Measure2] = SUM('Fact_Sales'[amount])
...
MEASURE 'table'[MeasureN] = SUM('Fact_Sales'[value])
Copy and Paste to DAX Query View window: copy the code from Excel and paste it into Power BI's DAX Query Window. Perform Unified Processing.
I hope my suggestions give you good ideas, if you have any more questions, please clarify in a follow-up reply.
Best Regards,
Carson Jian,
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Check out the February 2025 Power BI update to learn about new features.
User | Count |
---|---|
86 | |
80 | |
53 | |
39 | |
39 |
User | Count |
---|---|
104 | |
85 | |
47 | |
44 | |
43 |