Forum Discussion
Data consolidation
I have some data that I would like to consolidate. The data currently looks like this
(This data is copy and paste-linked from separate worksheets to create a large list of parts)
ITEM | PROFILE | LENGTH (mm) | WIDTH (mm) | GRADE | QTY | 420 kg |
RN1601 | N16 | 360 | 0 | _300PLUS | 54 | 31 kg |
RN1601 | N16 | 360 | 0 | _300PLUS | 3 | 2 kg |
RN1601 | N16 | 360 | 0 | _300PLUS | 2 | 1 kg |
But I want it to combine when it detects the same item number, profile, length, width & grade and add up the quantities and weight so that it looks like this
ITEM | PROFILE | LENGTH (mm) | WIDTH (mm) | GRADE | QTY | 423 kg |
RN1601 | N16 | 360 | 0 | _300PLUS | 59 | 34 kg |
Does anyone know if this is possible and how to do it?
Thank you
vschiralli You were just a few clicks away from the desired output. On the Design tab for the pivot table, select "Show in Tabular form" in the Report Layout group. and choose "Don't show Subtotals" in the Subtotals group. See attached.
10 Replies
- Rajesh_SinhaIron Contributor
What you are trying to achieve, the DATA CONSOLIDATION doesn't suits, because it summarizes the data and applies the selected aggregate function on all numeric values, other your sources data does have one ALPHANUMERIC column comprises the unit Kg.
Therefore I would like to suggest SUMPRODUCT with trick sums Alphanumeric column also.
- Formula in cell F50:
=SUMPRODUCT(($A$42:$A$46=$A50)*($B$42:$B$46=$B50)*($C$42:$C$46=$C50)*($D$42:$D$46=$D50)*($E$42:$E$46=$E50)*(SUBSTITUTE(F$42:F$46,"Kg","")+0))- Fill the formula across the range.
- Adjust cell references in the formula as needed.
**** Please marks this post as best solution if it solves the issue as well like.
- Subodh_Tiwari_sktneerSilver Contributor
Consider using a Pivot Table or you may use Power Query to group the data otherwise there are more than one way to achieve that.
- vschiralliCopper Contributor
Subodh_Tiwari_sktneer Thank you. I've tried pivot table but it didn't get the result i wanted. It made it quite complicated to look at. The people I'm sharing this data with need to keep it as simple as possible. This is what the pivot table looks like, which isn't really the outcome I'm after
I've just tried playing with power query, but it doesn't seem to group the data together.I'm not sure if you can see that, but the top 3 rows should be combined into 1 element (the Item numbers are the same) and the qty should be tallied up to 59 total. Rather than 3 rows for the same item
- Riny_van_EekelenPlatinum Contributor
vschiralli You can achieve this with a Pivot table, but you need to change the default formatting a little bit. See attached.
And with regard to power query, you connected to the table and data types were set. You haven't yet applied any step to transform/group the data.