Results 1 to 4 of 4
  1. #1
    4 Star Lounger
    Join Date
    Jul 2006
    Posts
    531
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Sum command to add values in all rows (2003)

    I need to do a query to add all the values of some specified rows but cannot work out the correct syntax.
    I have tried but cannot get it to work, see attached for example for what l am trying to achive.
    When l have done this l need to get a total of the complete column which contains the totals of all the rows.
    Any help would be appreciated.
    Attached Images Attached Images

  2. #2
    Gold Lounger
    Join Date
    Feb 2001
    Location
    Sint Niklaas, Belgium
    Posts
    2,778
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Sum command to add values in all rows (2003)

    There exist no function to sum all the fields of a query. You have to type all of them.
    Total : [Saf Circuit 1 - Saf] + [Saf Circuit 2 - Saf] + [Saf Circuit 3 - Saf] + [Saf Circuit 4 - Saf] + [Saf Circuit 5 - Saf]

    To total the column use View - Totals and change Group By by Sum.
    Francois

  3. #3
    4 Star Lounger
    Join Date
    Jul 2006
    Posts
    531
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Sum command to add values in all rows (2003)

    Hello,

    The sum function to total all fields appears to work, but l cannot get the total sum of all the columns to work.
    Firstly there is no row at the bottom which totals all the column and secondly for some reason of the totals of the rows appears to be incorrect, see screenshot.
    Attached is a screenshot of the query also.

    Huge screenshot shrunk by HansV
    Attached Images Attached Images

  4. #4
    Gold Lounger
    Join Date
    Feb 2001
    Location
    Sint Niklaas, Belgium
    Posts
    2,778
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Sum command to add values in all rows (2003)

    It is not possible to have all the record lines and a total line in one query. You have to do that on a form or on a report.
    Francois

Posting Permissions

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