I am trying to design a pivot table with dates as row headings, customer number as column headings, to analyze sales variances. I’m getting a ‘Grand Total’ row and column, but I also want to have a cumulative-to-date grand total as well. (See attached) The number of customers to be included in this table is going to continue to grow to over 100, but not all at one time, so I will need to have the columns generated as part of the pivot table. Any ideas or suggestions?
![]() |
There are isolated problems with current patches, but they are well-known and documented on this site. |
SIGN IN | Not a member? | REGISTER | PLUS MEMBERSHIP |
-
Pivot with two total columns? (2K-SR1)
Home » Forums » AskWoody support » Productivity software by function » MS Excel and spreadsheet help » Pivot with two total columns? (2K-SR1)
- This topic has 2 replies, 2 voices, and was last updated 20 years, 2 months ago.
AuthorTopicWSd_rasley
AskWoody LoungerMarch 8, 2005 at 7:40 pm #416815Viewing 0 reply threadsAuthorReplies-
WSsdckapr
AskWoody LoungerMarch 8, 2005 at 7:51 pm #933447I think you will need a macro.
The macro only needs to run the code to create the pivot table, then it just has to add the values down the column just past the pivot table.
If you record the steps with the macro recorder, it should get you almost 90% of the way there.
If the pivot is on a separate sheet, you add the code to the sheetactivate event and so whenever the sheet with the pivot is activated, the pivot will be updated and the column generated.If you need further assistance, please post back, and I can try to offer some details.
Steve
-
WSd_rasley
AskWoody LoungerMarch 10, 2005 at 3:08 pm #933834I tried to use a macro to create the pivot table but couldn’t quite get it the way I wanted, but it did give me time to re-think my strategy. Instead of using the pivot table to calculate the totals, I calculated the totals and had them included in the data pulled into the pivot table:
Date Customer Variance 1/1/05 Cust1 1.00 1/1/05 Cust2 2.00 1/1/05 Cust3 3.00 1/1/05 Week Total 6.00 1/1/05 YTD Total 6.00 1/8/05 Cust1 4.00 1/8/05 Cust2 5.00 1/8/05 Cust3 6.00 1/8/05 Week Total 15.00 1/8/05 YTD Total 21.00 The detail data was pulled onto one worksheet. On a second worksheet the ‘Week Total’ was calculated using a SumIf formula, while the ‘YTD Total’ is a simple C2+B3 formula. A macro copies all the data (pasted as values) onto the sheet that feeds the pivot table. When the pivot table refreshes it treats the two Total values as if they were normal ‘Customer’ values, resulting in a table looking like:
Date Cust1 Cust2 Cust3 Week Total YTD Total 1/1/05 1.00 2.00 3.00 6.00 6.00 1/8/05 4.00 5.00 6.00 15.00 21.00 I’m thinking that this method could make it easy to build a pivot table with multiple total columns.
-
Viewing 0 reply threads -

Plus Membership
Donations from Plus members keep this site going. You can identify the people who support AskWoody by the Plus badge on their avatars.
AskWoody Plus members not only get access to all of the contents of this site -- including Susan Bradley's frequently updated Patch Watch listing -- they also receive weekly AskWoody Plus Newsletters (formerly Windows Secrets Newsletter) and AskWoody Plus Alerts, emails when there are important breaking developments.
Get Plus!
Welcome to our unique respite from the madness.
It's easy to post questions about Windows 11, Windows 10, Win8.1, Win7, Surface, Office, or browse through our Forums. Post anonymously or register for greater privileges. Keep it civil, please: Decorous Lounge rules strictly enforced. Questions? Contact Customer Support.
Search Newsletters
Search Forums
View the Forum
Search for Topics
Recent Topics
-
Firefox 139
by
Charlie
1 hour, 19 minutes ago -
Who knows what?
by
Will Fastie
21 minutes ago -
My top ten underappreciated features in Office
by
Peter Deegan
8 seconds ago -
WAU Manager — It’s your computer, you are in charge!
by
Deanna McElveen
8 hours, 15 minutes ago -
Misbehaving devices
by
Susan Bradley
1 hour ago -
.NET 8.0 Desktop Runtime (v8.0.16) – Windows x86 Installer
by
WSmeyerbos
1 day, 1 hour ago -
Neowin poll : What do you plan to do on Windows 10 EOS
by
Alex5723
2 hours, 14 minutes ago -
May 31, 2025—KB5062170 (OS Builds 22621.5415 and 22631.5415 Out-of-band
by
Alex5723
1 day ago -
Discover the Best AI Tools for Everything
by
Alex5723
1 day ago -
Edge Seems To Be Gaining Weight
by
bbearren
14 hours, 46 minutes ago -
Rufus is available from the MSFT Store
by
PL1
22 hours, 48 minutes ago -
Microsoft : Ending USB-C® Port Confusion
by
Alex5723
2 days, 1 hour ago -
KB5061768 update for Intel vPro processor
by
drmark
1 hour, 28 minutes ago -
Outlook 365 classic has exhausted all shared resources
by
drmark
11 minutes ago -
My Simple Word 2010 Macro Is Not Working
by
mbennett555
1 day, 21 hours ago -
Office gets current release
by
Susan Bradley
2 days ago -
FBI: Still Using One of These Old Routers? It’s Vulnerable to Hackers
by
Alex5723
3 days, 14 hours ago -
Windows AI Local Only no NPU required!
by
RetiredGeek
2 days, 22 hours ago -
Stop the OneDrive defaults
by
CWBillow
3 days, 14 hours ago -
Windows 11 Insider Preview build 27868 released to Canary
by
joep517
4 days ago -
X Suspends Encrypted DMs
by
Alex5723
4 days, 3 hours ago -
WSJ : My Robot and Me AI generated movie
by
Alex5723
4 days, 3 hours ago -
Botnet hacks 9,000+ ASUS routers to add persistent SSH backdoor
by
Alex5723
4 days, 3 hours ago -
OpenAI model sabotages shutdown code
by
Cybertooth
4 days, 4 hours ago -
Backup and access old e-mails after company e-mail address is terminated
by
M W Leijendekker
3 days, 16 hours ago -
Enabling Secureboot
by
ITguy
3 days, 23 hours ago -
Windows hosting exposes additional bugs
by
Susan Bradley
4 days, 12 hours ago -
No more rounded corners??
by
CWBillow
4 days, 8 hours ago -
Android 15 and IPV6
by
Win7and10
3 days, 22 hours ago -
KB5058405 might fail to install with recovery error 0xc0000098 in ACPI.sys
by
Susan Bradley
5 days ago
Recent blog posts
Key Links
S | M | T | W | T | F | S |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | 6 | 7 |
8 | 9 | 10 | 11 | 12 | 13 | 14 |
15 | 16 | 17 | 18 | 19 | 20 | 21 |
22 | 23 | 24 | 25 | 26 | 27 | 28 |
29 | 30 |
Want to Advertise in the free newsletter? How about a gift subscription in honor of a birthday? Send an email to sb@askwoody.com to ask how.
Mastodon profile for DefConPatch
Mastodon profile for AskWoody
Home • About • FAQ • Posts & Privacy • Forums • My Account
Register • Free Newsletter • Plus Membership • Gift Certificates • MS-DEFCON Alerts
Copyright ©2004-2025 by AskWoody Tech LLC. All Rights Reserved.