Results 1 to 2 of 2

Thread: Query (2000)

  1. #1
    5 Star Lounger
    Join Date
    Jan 2001
    Thanked 0 Times in 0 Posts

    Query (2000)

    I have a totals query which is grouped on Region and then on Month and then I sum about 4 fields. I use this query in a report. The report has Western Region and the months of Sept, Oct, Nov (with Vision, Dental and Drug Sums) and then there is Central Region and the same months (with Vision, Dental and Drug sum).
    Western Region Vis Den Drg
    Sept 4 3 2
    Oct 5 6 1
    Nov 3 3 3

    Central Region
    Sept 1 1 1
    Oct 1 2 3
    Nov 4 4 4

    I would like to add Western Region Sept totals to Central Region Sept Totals and Western Region Oct totals to Central Region October Totals etc. Would I do this in the query? I know this sounds confusing but any help would be appreciated. Thanks.

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Thanked 31 Times in 31 Posts

    Re: Query (2000)

    To do this for one of the fields Vision, Dental or Drug, you could use a crosstab query, with Region as row heading and Month as colum heading (or vice versa) and e.g. Vision as value field (function = Sum). You can create crosstab queries for each of the fields you want to sum and then combine them into one - see ACC2000: How to Create a Crosstab Query with Multiple Value Fields.

Posting Permissions

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