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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
littlemojopuppy
Community Champion
Community Champion

Determine What Table a Measure is Defined On

Hi -

 

I don't think this is possible, but I'll try anyway.  I have two calculation items that are almost identical...

littlemojopuppy_0-1723495942852.png 

littlemojopuppy_1-1723495969398.png

Sales Category is a degenerate dimension on both tables (there is no dimension table for either field).  Was thinking that if I could determine what table a measure is defined on I could throw in an IF or SWITCH statement to use the appropriate filter.

 

Unfortunately, due to development standards, creating a calculated table for the dimension is not an option.

 

So is there a DAX function that returns what table a measure is defined on?

 

1 ACCEPTED SOLUTION

Most likely the home table can be retrieved via a DMV query. Definitely not via DAX.

View solution in original post

5 REPLIES 5
littlemojopuppy
Community Champion
Community Champion

Hola @lbendlin !

 

I could stick every measure in my model on the date table, or customer, or item or a free standing Report Measures table. Those measures could reference any field or other measure defined elsewhere in a model.  But measures have to be defined as part of a table somewhere.

 

I'll log into my work laptop to show this in a bit, but is there any way to reference what table a measure is actually defined on?

Screen snip of saving a model to folder with TE3.  Table is Sales Invoice Lines, clearly measures defined on a table.  Base Average Cost defined on that table.

littlemojopuppy_0-1723514849427.png

 

 

I want to know if there's a way to determine what table a given measure is defined on.

Most likely the home table can be retrieved via a DMV query. Definitely not via DAX.

I didn't think there was a DAX way of referencing the table a measure lives on.  Thank you for looking at it.

lbendlin
Super User
Super User

measures are defined on semantic models, not on tables.

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

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

June 2025 community update carousel

Fabric Community Update - June 2025

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