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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Replacing blanks with value based on ID

Hey I'm trying to replace the blanks in the subtotal column with the subtotal amount that corresponds to the Order ID. I made a mock table of it here 

NoahVeenstra2_0-1658413306222.png

My goal is this 

NoahVeenstra2_1-1658413405118.png

 

1 ACCEPTED SOLUTION

Oh, I see now you used my column name as part of the code.
You need to remove my name or the original column name.
Anyway you can PM me and we'll do it together in zoom

View solution in original post

6 REPLIES 6
SpartaBI
Community Champion
Community Champion

@Anonymous create this calculated column:

 

'Table'[Subtotal] = 
VAR _current_id = 'Table'[Order ID]
VAR _result = 
	SUMX(
		FILTER(
			'Table',
			'Table'[Order ID] = _current_id
		),
		'Table'[Price]
	)
RETURN
	_result

 


2022-05-19 17_30_22-Re_ Need help on DAX function with measure vs colu... - Microsoft Power BI Commu.png


Full-Logo11.png

SpartaBI_3-1652115470761.png   SpartaBI_1-1652115142093.png   SpartaBI_2-1652115154505.png

Showcase Report – Contoso By SpartaBI

Anonymous
Not applicable

This only returned "False" 

NoahVeenstra2_0-1658414781075.png

 

@Anonymous can you PM me to look together in a zoom?

 

Oh, I see now you used my column name as part of the code.
You need to remove my name or the original column name.
Anyway you can PM me and we'll do it together in zoom

Anonymous
Not applicable

Got it after that message, thanks! 

NoahVeenstra2_0-1658415113653.png

 

@Anonymous my pleasure 🙂
Check out my showcase report - got some high level stuff there. Sure you will find there a lot of cool ideas. 
https://community.powerbi.com/t5/Data-Stories-Gallery/SpartaBI-Feat-Contoso-100K/td-p/2449543
Give it a thumbs up over there if you liked it 🙂

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.