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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
SvenJ
Helper III
Helper III

Calculated sum Related to another table / list

Good morning everyone,

 

i have the following orignal list, where i receive the values, which need to be calculated (ENTRY LIST)

SvenJ_2-1642575490361.png

And this is the orginal table 

SvenJ_3-1642575627387.png

The result should look like this (FINAL_TABLE)

SvenJ_4-1642575863164.png

And here is what i need:

  • The FINAL TABLE should look in the ENTRY LIST, if the column Konto is between "Konto from" to "Konto to" and write the difference between EINGANG and AUSGANG in the correct column & row of the MONAT (1-12) / f.ex. B_No 1020
  • In B_No "1051" should be the sum of all rows between B_No from (1020) and B_No to (1045)

At the end i want to fill a matrix table with this values. Can anyone help me?

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@SvenJ , Based on what I got

 

You can add new column in Table 2 from Table1

 

Sumx(Filter(Table1, Table1[Kontoto] >= Table2[Konto From] && Table1[Kontoto] <= Table2[Konto to]) , [EINGANG] -  [AUSGANG])

 

 

If this does not help
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.

View solution in original post

2 REPLIES 2
v-robertq-msft
Community Support
Community Support

Hi, 

Have you followed the DAX formula posted by amitchandak to find the solution to your problem?

If so, would you like to mark his reply as a solution so that others can learn from it too?

 

If you still have a problem, you can post some sample data(without sensitive data) and your expected result.

How to Get Your Question Answered Quickly 

Thank you very much!

 

Best Regards,

Community Support Team _Robert Qin

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

amitchandak
Super User
Super User

@SvenJ , Based on what I got

 

You can add new column in Table 2 from Table1

 

Sumx(Filter(Table1, Table1[Kontoto] >= Table2[Konto From] && Table1[Kontoto] <= Table2[Konto to]) , [EINGANG] -  [AUSGANG])

 

 

If this does not help
Can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors