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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
Ghuiles
Advocate IV
Advocate IV

Is there a way to retrieve all measures?

Hello

 

Is there a way to retrieve all measures from one pbix file and export or copy them to a txt file?

That would help for further documentation and as well mass changes if needed.

Cheers.

2 ACCEPTED SOLUTIONS
Phil_Seamark
Employee
Employee

Hi @Ghuiles,

 

Yes there is.  You can run a DMV query against the Tabular cube.

 

Essentially you need to connect to your Power BI Desktop instance from a tool such AS Sql Server Management Studio (or MDX Studio) and issue the following Query

 

SELECT [CATALOG_NAME] as [DATABASE],
    CUBE_NAME AS [CUBE],[MEASUREGROUP_NAME] AS [FOLDER],[MEASURE_CAPTION] AS [MEASURE],
    [MEASURE_IS_VISIBLE]
FROM $SYSTEM.MDSCHEMA_MEASURES
 
This will output information on your measures

To learn more about DAX visit : aka.ms/practicalDAX

Proud to be a Datanaut!

View solution in original post

Hello 

 

I found a better solution, following that video: https://www.youtube.com/watch?v=rYlIp1PrBcA

 

2017-04-03 19_25_13-DaxStudio - 2.6.0.png

 

Basically, in the DAX Studio, you click on MDSCHEMA_MEASURES.

You get an SQL, execute it and you got a lot of details on your measures. 

That you can of course export directly to Excel.

 

Cheers

View solution in original post

22 REPLIES 22
Phil_Seamark
Employee
Employee

Hi @Ghuiles,

 

Yes there is.  You can run a DMV query against the Tabular cube.

 

Essentially you need to connect to your Power BI Desktop instance from a tool such AS Sql Server Management Studio (or MDX Studio) and issue the following Query

 

SELECT [CATALOG_NAME] as [DATABASE],
    CUBE_NAME AS [CUBE],[MEASUREGROUP_NAME] AS [FOLDER],[MEASURE_CAPTION] AS [MEASURE],
    [MEASURE_IS_VISIBLE]
FROM $SYSTEM.MDSCHEMA_MEASURES
 
This will output information on your measures

To learn more about DAX visit : aka.ms/practicalDAX

Proud to be a Datanaut!

Anonymous
Not applicable

Hi Phil, 

 

This is very helpful. I wonder if DAX Studio can acheive the same result.

Can I use the same query to extract all measures at once and perhaps copy to another dataset to be used in PBI?

 

Thanks!

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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