Hello, this is my first post here. I am tryin...

(Celson Aquino) #1

Hello, this is my first post here. I am trying to use an AppSheet formula to do a running total but I cannot find out how to do that.

Is it possible in AppSheet? Thanks in advance!

(Praveen Seshadri (AppSheet)) #2

Hi @Celson_Aquino, the concept of running total is not quite meaningful in your app, because there is no implicit order in the data (there is no “previous” row and “next” row). However, if each row has a date, for example, you can add a Virtual Column that computes the sum of all values in rows whose date is earlier than the date of the current row.

SUM(SELECT(TableName[ColumnName], [Date] < [_THISROW].[Date]))

(Celson Aquino) #3

Below is the real data where I need to use a runnng total.

I am using it in an AppSheet app but as a spreadsheet formula, so when I add new rows (records) on app, the formula is not added.

I think I can do what you said using the column “Order”. And, since In my case it will decrease the value, I will need do do something more.

Thank you!