9_0_4
9_0_4

Reputation: 3

How to tally up amount of values in a current row and above

I'm creating a spending sheet in google sheets, and I wanted to make it so the amount after column be the sum of amount value on the same row and up. I don't want to sum the entire column, because that'll just give me the entire column. How could I do this without manually hard coding every single row's equation?

Amount  Amount After
$500.00   $500.00
$140.00   $640.00 (Value of row 2 (without headers) and above, so row 1 and 2)
$50.00    $690.00 (Value of row 3 (without headers) and above, so row 1, 2, and 3)
$135.00 

I'm quite new to google sheets formulas, any pointers would be helpful!

Upvotes: 0

Views: 107

Answers (1)

nabais
nabais

Reputation: 2037

In your B3 cell, you can do the following:

  • option A: =B2+A3, then you can drag it below until where you want to want the values,
  • option B: =if(len(A3:A),B2+A3,) then you can drag until the end, and if the cell next to B have any number, it will automatically sum:

enter image description here

To drag, click on the lower right corner of a cell and drag it down with the mouse, or select the first cell you want to drag, then select the other cells you want to drag to, and then press: CTRL+D

enter image description here

Upvotes: 1

Related Questions