Results 1 to 2 of 2
  1. #1
    Join Date
    Jul 2002

    Unanswered: Running Sum Query

    I have a dataset consiting of text field, a short time field, a number field and a % field:

    [Procedure] [Time Elapsed] [#ofAttempts] [%ofTime]

    What I would like to do is to create a running sum query that would add the percent as a running sum grouped by [Time Elapsed] and [Procedure]. The end result would look like:

    COM 00:01 23.4%
    COM 00:02 45.6% (adding the 23.4% that occured within 1 minute with the 22.2% that occured within 2 minutes)
    IVA 00:01 10.2%
    IVA 00:02 20.6%
    So on and so on. Microsoft say this can be done with a DSum expression, but I have used their two example and tried to alter them without any success. Any help would be appreciated.

  2. #2
    Join Date
    May 2002
    The documentation for DSum is not clear to me either. If you can't find someone else to explain how to use it, depending on where you want to use a running total, you could retrieve the raw numbers and use code to loop through them and calculate the running total, or if you want it in an Access report, use RunningSum.


    John Lambert
    Team Database
    The International Association Of Database Professionals

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts