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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
Anonymous
Not applicable

How to evaluate measure and several dimensions?

I want to check a new measure using DAX query.

In model I have one fact table and three dimension tables. In excel PIvotTable I can put a measure to the Values section and put 3 separate dimension table attributes to Rows section. I would like to do the same query using DAX.
Probably, the query should be looks like this example (it doesn't work):

EVALUATE (
	FILTER (
		ADDCOLUMNS (
			VALUES( DimensionTable1[ColumnName1] ),
			VALUES( DimensionTable2[ColumnName2] ),
            VALUES( DimensionTable3[ColumnName3] ),
			"Measure", [Measure]
		),
		DimensionTable1[ColumnName1] IN {( Value1 ), ( Value2 )},
		DimensionTable2[ColumnName2] IN {( Value3 ), ( Value4 )}
	)
)

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

EVALUATE
    CALCULATETABLE(
    
        SUMMARIZECOLUMNS(
            DimensionTable1[ColumnName1],
            DimensionTable2[ColumnName2],
            DimensionTable3[ColumnName3]
            "Measure", [Measure]
        ),
        
        TREATAS(
            {Value1, Value2},
            DimensionTable1[ColumnName1]
        ),
        TREATAS(
            {Value3, Value4},
            DimensionTable2[ColumnName2]
        )
    )

View solution in original post

2 REPLIES 2
amitchandak
Super User
Super User

@Anonymous , what are trying to achieve here. If you have tables and they are related, filter from dimension slicer will be taken care of by power bi?

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube
Anonymous
Not applicable

EVALUATE
    CALCULATETABLE(
    
        SUMMARIZECOLUMNS(
            DimensionTable1[ColumnName1],
            DimensionTable2[ColumnName2],
            DimensionTable3[ColumnName3]
            "Measure", [Measure]
        ),
        
        TREATAS(
            {Value1, Value2},
            DimensionTable1[ColumnName1]
        ),
        TREATAS(
            {Value3, Value4},
            DimensionTable2[ColumnName2]
        )
    )

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.