在 Excel 数据透视表中显示累计值
在 Excel 中打开“值字段设置 > 值显示方式”,选择“按某一字段累计”,并指定沿其累计的字段,通常是日期或月份。最后一项应等于总计。Google Sheets 若没有同样选项,可在按月排序的旁边用 =SUM($B$2:B2) 计算累计。
本文目录
快速解答
在 Excel 中打开“值字段设置 > 值显示方式”,选择“按某一字段累计”,并指定沿其累计的字段,通常是日期或月份。最后一项应等于总计。Google Sheets 若没有同样选项,可在按月排序的旁边用 =SUM($B$2:B2) 计算累计。
=7800
=7800+5400
=7800+5400+8850
=7800+5400+8850+2400检查要点
八行样本的月合计为 7800、5400、8850、2400。2026 年 11 月 12 日测试中,累计加法得到 7800、13200、22050、24450,最后一项等于收入总计。可以把收入拖进值区域两次,一次求和,一次按月累计,并改好第二个字段的名称。
边界与兼容性
以文本存储的月名会按字母排序(Apr、Feb、Jan、Mar),从而打乱累计,应使用真正的日期或月初辅助列。若沿产品累计,得到的是产品之间的累计而不是年初至今。若最后一项不是 24450,可能选错了基准字段、筛选隐藏了某个月,或值仍是计数。
完整英文示例、公式与作者备注
Excel How-toTested in: The monthly cumulative figures below were evaluated in Google Sheets on 12 November 2026. Excel 365 menu names are the current desktop labels; I did not click Show Values As in Excel this session.
This is a display option, like percentage of total. It is not a calculated field.
Turn on Running Total In (Excel)
- Click a number in the Values area.
- Open Value Field Settings, then the Show Values As tab.
- Choose Running Total In.
- In the Base field box, pick the field the total should run along — typically Date or Month, not Product.
- Click OK. Drag Revenue into Values a second time if you also want the month’s own amount next to the running total.
On the eight-sale sample the monthly sums are 7800 (Jan), 5400 (Feb), 8850 (Mar), and 2400 (Apr). In Google Sheets on 12 November 2026 the cumulative additions were:
=7800
=7800+5400
=7800+5400+8850
=7800+5400+8850+2400
Those returned 7800, 13200, 22050, and 24450. A pivot running total down the month list should match those four figures, and the last one should equal the Revenue grand total of 24450.
To show both the month amount and the running total, add Revenue twice: leave one as Sum, set the other to Running Total In Month, and rename the second field so the captions are clear.
Google Sheets, and checking the order
If your Sheets pivot editor has a Show as > Running total (or similar) option, use it the same way and check it against the 7800 / 13200 / 22050 / 24450 sequence. If it does not, put the months in a column, sort them, and fill:
=SUM($B$2:B2)
next to the first month amount in B2. That formula is the sheet equivalent of Running Total In.
Month names stored as text sort as Apr, Feb, Jan, Mar, which will scramble a running total. Use real dates and group them, or a month-start helper =DATE(YEAR(A2),MONTH(A2),1), so January comes before February.
Running Total In Product would accumulate across products instead of across months — useful for a different question, wrong if you wanted a year-to-date. If the last number is not 24450, you chose the wrong base field, a filter is hiding a month, or Values is still a Count.
A line chart of the running total should end at 24,450. If the chart drops April, the source range is short; see chart not showing all data.