ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Subtotal twice (https://www.excelbanter.com/excel-discussion-misc-queries/156856-subtotal-twice.html)

michelle

Subtotal twice
 
Original data:
Vendor Type Amt
Vend A Stationery 1
Vend A Stationery 2
Vend A Welfare 3
Vend A Fixture 1
Vend B Stationery 3
Vend B Stationery 2
Vend B Fixture 1
Vend B Fixture 2

Required to get (1) Individual Vendor Total and (2) Individual Type Total
Question: How to achieve the following result using Subtotal?
Vendor Type Amt
Vend A Stationery 1
Vend A Stationery 2
Stationery Total 3
Vend A Welfare 3
Welfare Total 3
Vend A Fixture 1
Fixture Total 1
Vend A Total 13
Vend B Stationery 3
Vend B Stationery 2
Stationery Total 5
Vend B Fixture 1
Vend B Fixture 2
Fixture Total 3
Vend B Total 16
Grand Total 30


JMB

Subtotal twice
 
Select your table and click Data/Subtotal at each change in Vendor, use
function Sum on Amt column. Repeat for each change in Type, use function Sum
on Amt column (and uncheck the box that says "Replace current subtotals").

Be sure your table is sorted/grouped by vendor and type before subtotaling.




"Michelle" wrote:

Original data:
Vendor Type Amt
Vend A Stationery 1
Vend A Stationery 2
Vend A Welfare 3
Vend A Fixture 1
Vend B Stationery 3
Vend B Stationery 2
Vend B Fixture 1
Vend B Fixture 2

Required to get (1) Individual Vendor Total and (2) Individual Type Total
Question: How to achieve the following result using Subtotal?
Vendor Type Amt
Vend A Stationery 1
Vend A Stationery 2
Stationery Total 3
Vend A Welfare 3
Welfare Total 3
Vend A Fixture 1
Fixture Total 1
Vend A Total 13
Vend B Stationery 3
Vend B Stationery 2
Stationery Total 5
Vend B Fixture 1
Vend B Fixture 2
Fixture Total 3
Vend B Total 16
Grand Total 30



All times are GMT +1. The time now is 03:05 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com