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

Vote for your favorite vizzies from the Power BI Dataviz World Championship submissions. Vote now!

Reply
Anonymous
Not applicable

Create a Calculated Column from Different Tables/ queries based on calculation columns

Hi All,

 

need some help in creating the calculation 

 

 I have 3 queries 

 

 below listed is actual data output from the Queries 

 

Query 1

 

DescriptionAmount 
BUCKET 1$575.00 
BUCKET 2$285.00 
BUCKET 3$135.00 
BUCKET 4$155.00BUCKET 1 -(BUCKET 2 + Bucket 3)
BUCKET 5$125.00 

 

Query 2: output 

 

DescriptionAmount 
BUCKET 6$100.00 
BUCKET 7$70.00 
BUCKET 8$25.00 
BUCKET 9$5.00(BUCKET 6 - (Bucket 7 + Bucket 8))
BUCKET 10$45.00 

 

Query 3: Output 

 

DescriptionAmount 
Bucket 11100 
Bucket 1245 
Bucket 1325 
Bucket 1430(Bucket 11 - ( Bucket 12+Bucket 13))

 

 

Problem / Help required

 

I have to create a New Calculation which has to be calculated like below

 

Bucket 15 = BUCKET 4 + Bucket 9 + Bucket 14

 

Can someone please help me with this, as I don't know how to create a calculation on top a row inside the table.

 

Thanks in advance 

 

 

1 ACCEPTED SOLUTION
v-xicai
Community Support
Community Support

Hi @Anonymous ,

 

You can create measure like DAX below.

 

Sum=

var d4 = CALCULATE(MAX(Query 1[Amount]),FILTER(Query 1,Query 1[Description]="BUCKET 4"))

var d9 = CALCULATE(MAX(Query 2[Amount]),FILTER(Query 2,Query 2[Description]="BUCKET 9"))

var d14 = CALCULATE(MAX(Query 3[Amount]),FILTER(Query 3,Query 3[Description]="BUCKET 14"))

return d4 +d9 +d14

 

Best Regards,

Amy

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

 

View solution in original post

2 REPLIES 2
v-xicai
Community Support
Community Support

Hi @Anonymous ,

 

You can create measure like DAX below.

 

Sum=

var d4 = CALCULATE(MAX(Query 1[Amount]),FILTER(Query 1,Query 1[Description]="BUCKET 4"))

var d9 = CALCULATE(MAX(Query 2[Amount]),FILTER(Query 2,Query 2[Description]="BUCKET 9"))

var d14 = CALCULATE(MAX(Query 3[Amount]),FILTER(Query 3,Query 3[Description]="BUCKET 14"))

return d4 +d9 +d14

 

Best Regards,

Amy

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

 

 

Anonymous
Not applicable

@v-xicai  thanks it worked 🙂

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

Vote for your favorite vizzies from the Power BI World Championship submissions!

Sticker Challenge 2026 Carousel

Join our Community Sticker Challenge 2026

If you love stickers, then you will definitely want to check out our Community Sticker Challenge!

January Power BI Update Carousel

Power BI Monthly Update - January 2026

Check out the January 2026 Power BI update to learn about new features.

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.