SQL for running average calculations

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • MLH

    SQL for running average calculations

    I've seen suggestions showing how to display running averages
    on reports in this NG, but not too much on displaying them with
    a query. I'm wondering if it's just not possible, or if it's just not
    popular.

    Suppose you have a table, tblPmtsRcd with amounts & dates
    spanning a 24-month period. Now suppose you'd like a query
    to display 24 records (for the 24 months) with 2-columns: the
    first showing the sum of payments received each month and
    the second showing the running average of all monthly cash
    receipts from the beginning up through the current month for
    each row.

    SQL that would accomplish this would be an elegant way to
    feed data to a graph. But I didn't see any examples to follow.

  • lyle fairfield

    #2
    Re: SQL for running average calculations

    MLH <CRCI@NorthStat e.netwrote in
    news:vvmat3dkua nm9tipe8niom0ld 1ss6hfal2@4ax.c om:
    I don't care to change 8-years of higher
    education because some crippled brained intellectual on the Access
    Development Team doesn't know what a Cartesion plane is.
    It's hard to change the colour of those reeds after the basket is wove.

    Comment

    Working...