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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
seabrew
Helper II
Helper II

Create a measure that SUMs based on two other fields in the same row

 

I am trying to do this for a median value against the aggregated values of two columns in the same row. Can someone help me with the DAX? I got it to work with SUMMARIZE and CALCULATETABLE, but I need a scalar value in order to work in the Pivot Table / Matrix. I then want to do a MEDIAN function against the new measure. 

 

Sample data is here. I want to group by Client and AsOfDate to get the Client SUM for the AsOfDate and return that value to each account belonging to the client on the AsOfDate. 

 

AccountClientValueAsOfDateNew Measure - Client SUM Value
123A105/31/201725
234A155/31/201725
658B205/31/201720
98C305/31/201730
123A204/30/201785
234A654/30/201785
658B674/30/201767
98C324/30/201732
1 REPLY 1
v-huizhn-msft
Microsoft Employee
Microsoft Employee

Hi @seabrew,

I am still confusing your requirement, could you please list an example to display what you want? How to display each account belonging to the client on the AsOfDate? 

>> I then want to do a MEDIAN function against the new measure. 

You can create a measure using the formula: median=MEDIAN(Table[NewMeasure]). Then show it in a card visual to check if it works fine. For MEDIAN function, please review the blog.

Best Regards,
Angelia

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors