Results 1 to 3 of 3
  1. #1
    Lounger
    Join Date
    Nov 2003
    Location
    St. Paul, Minnesota, USA
    Posts
    29
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Query to Total by Year (2002)

    My database is set up (thanks to you guys) to track contributions to charities.

    I have 5 different entities ([DonorID]) who have been making donations to many different charities over the last several years [CalendarYear] and will continue to do so into the future.

    I will be creating one report for each entity. The reports are run from one of five queries (one for each DonorID) that asks for a beginning and ending year, therefore, the reports could show any number of years. All my reports show totals by year by charity, but I want a report footer that gives me grand totals of all contributions by calendar year by donor, i.e. "Total Contributions for 2001 = $X" and "Total Contributions for 2002 = $X", depending on what years the user selected. The fields involved will be [Amount], [AmountTaxDed], [AmountNoTax], [CalendarYear], and [DonorID].

    Logic tells me I need to design a query to sum the dollar amounts by year and then turn it into a sub report, but I don't know how to make this second query match the year parameters that the user entered to create the main report.

    Thanks!
    Shelly

  2. #2
    Plutonium Lounger
    Join Date
    Mar 2002
    Posts
    84,353
    Thanks
    0
    Thanked 29 Times in 29 Posts

    Re: Query to Total by Year (2002)

    The easiest "solution", although not quite what you want, would be to group the report by year, and to display the yearly total in the group footer. You would automatically get totals for the selected years only.

    Would that be acceptable?

  3. #3
    Lounger
    Join Date
    Nov 2003
    Location
    St. Paul, Minnesota, USA
    Posts
    29
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Query to Total by Year (2002)

    I ended up using a sub-report that returns totals for all years, not just the ones that the user requested for the report. As of today, that was an acceptable compromise.

    Thanks for your help.

Posting Permissions

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