Forum Discussion
gorankocinski
8 years agoNew Member
New column sum formula help
hi, I have one document with 2 tables in it. In the first table there are 2 columns A with unic ID of some business and B with given funds by state. for example Table name - GivenFunds ID,...
- 8 years ago
Hi Greg_Deckler,
In your scenario, have you created any relationship between the two tables? If not, please create one. Then you can try following calculated column:
Column = CALCULATE ( SUM ( SecondTable[Cost] ), FILTER ( FirstTable, FirstTable[ID] = EARLIER ( FirstTable[ID] ) ) )And once you create the relationship Greg_Deckler's solution should not return errors.
Thanks,
Xi Jin.
Ashish_Mathur
8 years agoSuper User
Hi,
Try this
- Assuming that there are no repetitions in the ID column of the first table, create a relationship from the ID column of the second table to the ID column of the first table
- From the first table, dag the ID to you visual
- Write the following measures
Total Funds = SUM(Table1[Funds])
Total Cost = SUM(Table2[Cost])
Hope this helps.
gorankocinski
8 years agoNew Member
Ashish_MathurI dont need measures, i have done this in visual... now i need column with this data.
In Pivot in Excel this can be done in seconds, but i have problem with Power BI, I am new here