Results 1 to 3 of 3
  1. #1
    New Lounger
    Join Date
    Jun 2004
    Posts
    13
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Query Total (MS2000)

    I have a query that returns the total for a month, My problem is that if there isn't any records for that month how can I get it to return a Zero

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

    Re: Query Total (MS2000)

    You need to have a table that lists all months.
    Create a query based on the table and on the query you already have, with an outer join on the month so that ALL records from the table are returned.
    Use the Nz function to replace empty (null) totals by 0.

  3. #3
    Plutonium Lounger
    Join Date
    Dec 2000
    Location
    Sacramento, California, USA
    Posts
    16,775
    Thanks
    0
    Thanked 1 Time in 1 Post

    Re: Query Total (MS2000)

    There was a discussion of a similar question in this thread.
    Charlotte

Posting Permissions

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