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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
MrPatrick
Helper I
Helper I

PowerQuery / M - Calculate total of multiple values

 

I have two tables,

Table A (list_backup) has multiple entries for each key, table B (list) has single entries for the key.

Table A has a column 'called_count' that I would like to sum and add to a column in table B, per key

 

In the example below I need to calculate the column highlighted in red, totalCall.

Annotation 2020-03-03 122704.png

I can do this in DAX but I need to use TotalCall on an X axis and so need to calculate it in my query instead.

 

Can anyone help, I thought I'd found a solution here but I'm struggling to understand how to modify it to apply to my data.

1 ACCEPTED SOLUTION
Saurabh8437
Frequent Visitor

You can open Power Query Editor and duplicate your table. 

 

Perform Group By on second table in Power Query Editor itself and you will have two tables with desired result. 

View solution in original post

2 REPLIES 2
v-lionel-msft
Community Support
Community Support

Hi @MrPatrick ,

 

First, copy and paste the list_backup table;

Second, use "Group By" feature in the list_backup(2) table

y7.PNGy8.PNG

 

Best regards,
Lionel Chen

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

 

Saurabh8437
Frequent Visitor

You can open Power Query Editor and duplicate your table. 

 

Perform Group By on second table in Power Query Editor itself and you will have two tables with desired result. 

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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