Forum

Concatenate & S...
 
Notifications
Clear all

Concatenate & Sumifs in Power Query

7 Posts
2 Users
0 Reactions
170 Views
(@jason-wier)
Posts: 23
Eminent Member
Topic starter
 

Good afternoon. 

I have a file that I would like to Concatenate two ROWS and then sumif based on two conditions using Power Query.

The attached file provides the specific details. 

Thank you for the insight.

 
Posted : 04/09/2022 2:02 pm
Riny van Eekelen
(@riny)
Posts: 1194
Member Moderator
 

Hi Jason,

Please try to upload the file again as it didn't follow through. Don't forget to press "Start upload" before pressing Submit Reply.

Riny

 
Posted : 05/09/2022 1:36 am
(@jason-wier)
Posts: 23
Eminent Member
Topic starter
 

Please find attached file.  

 
Posted : 07/09/2022 9:08 am
Riny van Eekelen
(@riny)
Posts: 1194
Member Moderator
 

The trick here is to first define a named range of the data you want to use. Connect to that range with PQ and Transpose the table. Now merge the first two columns and Transpose the table back and Promote the Headers and do some cleaning up. Please see if you can follow what I did in the attached file.

Note that I inserted a column title in the data for "FPR Line Name".

Insecure though what you mean by the SUMIF part of your question.

 
Posted : 07/09/2022 9:50 am
(@jason-wier)
Posts: 23
Eminent Member
Topic starter
 

This is very helpful and resolves my first question.  Excellent and thank you!

The 2nd part of the question for the sumif is this: 

I want to sum all values in a row that have "Actual+Adjustment" within the column header.  Example within the myData attachment: Sum Columns D+F+H, etc.

Then a seperate sum total for all values that have "Plan" in the column header. Example within the myData attachment: Sum Columns E+G+I, etc.

 
Posted : 07/09/2022 3:47 pm
Riny van Eekelen
(@riny)
Posts: 1194
Member Moderator
 

Okay, I hadn't noticed these two columns at the end. Please have a look at the attached revised workbook.

 
Posted : 08/09/2022 12:18 am
(@jason-wier)
Posts: 23
Eminent Member
Topic starter
 

OUTSTANDING, Riny!  This is exactly what was needed AND an incredible learning resource for myself, and I'm sure others.  I can't thank you enough. Awesome job! 

 
Posted : 08/09/2022 1:49 pm
Share: