A field from last record to auto enter into a field in a new record

WarriorMCB

Registered User.
Local time
Today, 11:17
Joined
Jul 20, 2004
Messages
27
I'm looking to do a simple inventory where what comes in (form 1) and what goes out (form 2) are taken away to leave a total. This total needs to be added to the next 'what comes in' form when new inventory is recorded. Is it possible to have a vba or something that can take the last field record sum from form 2 and put it into a field in form 1 (to a new record)
I have a query that does the math from the two tables (forms) that give the remaining total on that given date. Now I need that total to be added when more inventory comes in, giving me a bigger total than what came in. Can a new record, record a value from the previous record so that it can sum a new value in that new record.
I hope that's not confusing.

Thankyou
 
Hi. Not sure storing the previous total is necessary. All that calculations should be possible using a query.
 
Yes, however, I need to add the sum from the last record without having to type it. A query reads and can sum from the same row but I need it to sum from the previous record.
 
Yes, however, I need to add the sum from the last record without having to type it. A query reads and can sum from the same row but I need it to sum from the previous record.
Hi. A query can do that. Look up running sum examples.

Sent from phone...
 
A query reads and can sum from the same row but I need it to sum from the previous record.

No, a query can add the value in the same field in different rows together:


Your method is the incorrect way to do this, a "running sum query" (search the forum for this term, or go to the bottom to see recommended similar posts) is the correct way. Essentially, you don't store the current balance, you just have the computer calculate it up to the point you need whenever you need.
 
I have no idea what a running sum is, let alone know how to do it. I just need one little field from the previous record to be calculated in the current row and field. I'm totally lost. Without a multitude of code I guess I'm at a stand still.

thank you anyways
 
I have no idea what a running sum is, let alone know how to do it. I just need one little field from the previous record to be calculated in the current row and field. I'm totally lost. Without a multitude of code I guess I'm at a stand still.

thank you anyways
Hi. See if the SQL I posted in this other thread helps you understand what I mean by calculating previous balance without storing it.
The result looks like this.
1603125421788-png.85908
 
Did you search the forum? Did you check on the link at the bottom of this page titled "Running sum Query"? What specific issues do you have after reading those posts?
 
Hi. See if the SQL I posted in this other thread helps you understand what I mean by calculating previous balance without storing it.
The result looks like this.
1603125421788-png.85908
Yes this looks like what I am wanting to achieve.
 
Did you search the forum? Did you check on the link at the bottom of this page titled "Running sum Query"? What specific issues do you have after reading those posts?
Issue is I have no idea what I'm seeing let alone know how to type the formula after seeing what I saw.
 
Hi. See if the SQL I posted in this other thread helps you understand what I mean by calculating previous balance without storing it.
The result looks like this.
1603125421788-png.85908
Can you help me achieve this please. Thankyou
 

Users who are viewing this thread

Back
Top Bottom