Products se vba to sum qty

Graham JN

New Member
Joined
Apr 15, 2018
Messages
13
Help lol
i have data in a sheet and it is variable number of rows always changes.
within each row of data is various columns of data.
i would like it to consolidate the data to a new sheet so that any identical product codes are consolidated so I just have number of products for each code.

Product code
qtyPrice buyingSelling £Total
A12343203090
A12343203090
A12353203090
results are like
A12346
A12353

<tbody>
</tbody>
 

Excel Facts

Best way to learn Power Query?
Read M is for (Data) Monkey book by Ken Puls and Miguel Escobar. It is the complete guide to Power Query.
Welcome to the MrExcel board!

Excel's built-in Pivot Table feature can do that for you.

1. Select A1:B(end of data) That is Product code & qty columns, including headings.
2. 'Insert' ribbon tab -> PivotTable -> OK
That should produce a new sheet with a PivotTable panel at the right. In that panel ..
3. Click & drag Product code text from the top section to the 'Rows' section at bottom left
4. Click & drag the qty text from the top section to the 'Values' section at the bottom right
All done :)

Here is the result for me:

Excel Workbook
AB
1
2
3Row LabelsSum of qty
4A12346
5A12353
6Grand Total9
7
Sheet5
 
Upvote 0

Forum statistics

Threads
1,215,064
Messages
6,122,936
Members
449,094
Latest member
teemeren

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top