Forum Discussion
Merging Tables with Addition Function
I have two tables. They both have two columns. A category column and then a count for that category.
Example:
Table #1
Column 1 Column 2
Abuse 45
Table #2
Column 1 Column 2
Abuse 3
I want to join these two tables so that the category is summed.
In this example Abuse would be summed at 48.
Any non-matching rows would simply get their own row and count.
So in this example there is clearly two rows between the two tables with a category of Abuse.
However, maybe there’s a row category of ‘Antagonism’ that doesn’t have any other match. It gets its own row.
Jimbo
Try appending the two tables.
Go to Home - Edit Queries - Append Queries - Append Queries as New.
If you add the Colum 1 and Column 2 to a Table visual, it should display the summarised values.
If you need to create a data table of the summarised values, you can use the SUMMARIZE() DAX function.
If this solves your problem please mark as teh solution.
9 Replies
- NipponSahoreResolver II
I would do the following :
- Append the two tables together
- Group the resultant by Column 1 and calculate the sum of Column 2
- jimbolyaRegular Visitor
Nope - abuse is still 45...needs to be 48 in order for me to know the operation worked...
- NipponSahoreResolver II
Should not be. Do you still see 2 Abuse after grouping the data?
- anandavSkilled Sharer
Try appending the two tables.
Go to Home - Edit Queries - Append Queries - Append Queries as New.
If you add the Colum 1 and Column 2 to a Table visual, it should display the summarised values.
If you need to create a data table of the summarised values, you can use the SUMMARIZE() DAX function.
If this solves your problem please mark as teh solution.
- jimbolyaRegular Visitor
I will try this.
However, I've never used the SUMARIZE DAX function...
That part will probaby not go well lol.
Jimbo