Moving Range in a Query?

irish634

Registered User.
Local time
Today, 18:02
Joined
Sep 22, 2008
Messages
230
I have been able find threads on moving/running averages etc, but is there a way to perform a moving range calculation in a query? I need to calculate the range between a current row and the previous row.

Here is an example:
Capture.JPG

I can certainly accomplish this in a couple of other ways, code, creating a recordset, etc., but I was wondering if anyone has done this in a query? If so, how?

Thanks
 
Hi Craig. There are few example on how to refer to previous or next records in a query. One important aspect to remember is there has to be something you can use to sort the data to make sure it is in the correct order to determine which record is previous to which one. If you do a search on "running sum" or "running total," you'll see some examples of several approaches to refer to previous rows in a query.
 

Users who are viewing this thread

Back
Top Bottom