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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
pang22
Helper III
Helper III

combine and summarize the qty into one table

Hello,

 

I have two tables, how to use DAX to combine and summarize the qty into one table (third photo)?

 

 

pang22_1-1702025231028.png

 

pang22_2-1702025245138.png

 

pang22_3-1702025255567.png

 

1 ACCEPTED SOLUTION
v-zhangti
Community Support
Community Support

Hi, @pang22 

 

You can try the following methods.

Method 1:

Measure = CALCULATE(SUM('Table 2'[Potential]),FILTER(ALL('Table 2'),[Factory]=SELECTEDVALUE('Table 1'[Factory])&&[Date]=SELECTEDVALUE('Table 1'[Date])))

vzhangti_0-1702262421692.png

Method 2:

New table:

New table = SUMMARIZE('Table 1','Table 1'[Factory],'Table 1'[Date],"Order OH",SUM('Table 1'[Order OH]),"Capacity",SUM('Table 1'[Capacity]))
Column = CALCULATE(SUM('Table 2'[Potential]),FILTER('Table 2',[Factory]=EARLIER('New table'[Factory])&&[Date]=EARLIER('New table'[Date])))

vzhangti_1-1702262692472.png

Is this the result you expect? Please see the attached document.

 

Best Regards,

Community Support Team _Charlotte

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

1 REPLY 1
v-zhangti
Community Support
Community Support

Hi, @pang22 

 

You can try the following methods.

Method 1:

Measure = CALCULATE(SUM('Table 2'[Potential]),FILTER(ALL('Table 2'),[Factory]=SELECTEDVALUE('Table 1'[Factory])&&[Date]=SELECTEDVALUE('Table 1'[Date])))

vzhangti_0-1702262421692.png

Method 2:

New table:

New table = SUMMARIZE('Table 1','Table 1'[Factory],'Table 1'[Date],"Order OH",SUM('Table 1'[Order OH]),"Capacity",SUM('Table 1'[Capacity]))
Column = CALCULATE(SUM('Table 2'[Potential]),FILTER('Table 2',[Factory]=EARLIER('New table'[Factory])&&[Date]=EARLIER('New table'[Date])))

vzhangti_1-1702262692472.png

Is this the result you expect? Please see the attached document.

 

Best Regards,

Community Support Team _Charlotte

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

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.

Top Solution Authors