Sub topic 6
Building monthly roll-ups from a ledger
Assume you know basic Excel formulas, relative and absolute references, and the structure of a simple budget or financial statement. This chapter uses a flat ledger: one row per transaction, with fields for date, account, category, and amount.
Start with a usable ledger
A monthly roll-up summarizes many ledger rows into one report row. Each ledger row should contain one transaction, rather than a subtotal mixed with transaction data.
| Ledger column | Example | Purpose |
|---|---|---|
| Account | Rent expense | Identifies the reporting line |
| Category | Opex | Groups related accounts |
| Date | 2026-01-15 | Determines the reporting month |
| Amount | 2500 | Value to total |
Keep the date column as real Excel dates, not text such as January 2026. Store month headings in the roll-up as the first day of each month, then format them as mmm-yy.
Build the monthly SUMIFS formula
SUMIFS is an aggregation function: it adds the amounts from every row that meets all supplied criteria. Its first argument is the amount range. After that, provide pairs of criteria ranges and criteria.
Suppose:
Data!F2:F5000contains amounts.Data!B2:B5000contains account names.Data!D2:D5000contains transaction dates.A10contains the account label.C3contains the first day of the month.
Enter this formula in C10:
=SUMIFS(Data!$F$2:$F$5000,Data!$B$2:$B$5000,$A10,Data!$D$2:$D$5000,">="&C$3,Data!$D$2:$D$5000,"<"&EDATE(C$3,1))The formula applies three filters:
- The account equals the label in
$A10. - The date is on or after the month start in
C$3. - The date is before the first day of the next month.
The & joins an operator such as ">=" to a cell value. The less-than test for the next month is safer than testing for the last day of the current month because transaction dates may include times. A transaction at 23:00 on the last day still belongs to the month.
Copy the formula across the model
The dollar signs control which references move:
$A10locks column A, so copying right keeps the account label in column A. The row can change when copying down.C$3locks row 3, so copying down keeps the month header. The column can change when copying right.$F$2:$F$5000and the other data ranges are fully absolute, so they never move.
Copy the formula right for additional months and down for additional accounts. Format the result as currency or another appropriate financial format.
To roll up a category instead, change the criteria range and criterion:
=SUMIFS(Data!$F$2:$F$5000,Data!$C$2:$C$5000,$A10,Data!$D$2:$D$5000,">="&C$3,Data!$D$2:$D$5000,"<"&EDATE(C$3,1))Check the roll-up
A formula can return zero because no rows match, or because the source data is incomplete. Add a reconciliation row that compares the report total with the ledger total for the same scope. For a complete report, a difference other than zero requires investigation.
Bounded ranges such as row 2 through row 5000 make the calculation scope visible. If the ledger grows, update the bound or use an Excel Table with structured references. Do not silently include unrelated rows below the ledger.
Exercise
Write a formula for account A10 and month header C$3 that sums Data!F2:F5000 when the account is in Data!B2:B5000 and the date falls within that month.
Show answer
=SUMIFS(Data!$F$2:$F$5000,Data!$B$2:$B$5000,$A10,Data!$D$2:$D$5000,">="&C$3,Data!$D$2:$D$5000,"<"&EDATE(C$3,1))