Applying Criteria to a record count based in query

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • dmne05974
    New Member
    • Oct 2008
    • 5

    Applying Criteria to a record count based in query

    As a novice in Access i am currently writing a database to track certain financial information for a non-profit organisation. As part of the funding they have to monitor age ranges and ethnic minority, this is done with 4 yes/no fields controlled on a form with Bi-state check boxes (minor, adult, ethnicminor, ethnicadult).

    The database stores many purchase orders for each person as more money is awarded however each person can only be counted once. Data from two tables (Customer, PuchaseOrder) is used to query by a financial quarter, grouping all the similar references, and then a record count applied in a second query counting the number of records returning results.

    The problem I am having is that regardless of a value (-1 or 0) the record is counted unless each box is unchecked. I have tried putting ' <>0' in the criteria box of the count but this does not work. Other than writing a query for each individual field is there anything I can do?

    Thanks in advance
  • PianoMan64
    Recognized Expert Contributor
    • Jan 2008
    • 374

    #2
    Originally posted by dmne05974
    As a novice in Access i am currently writing a database to track certain financial information for a non-profit organisation. As part of the funding they have to monitor age ranges and ethnic minority, this is done with 4 yes/no fields controlled on a form with Bi-state check boxes (minor, adult, ethnicminor, ethnicadult).

    The database stores many purchase orders for each person as more money is awarded however each person can only be counted once. Data from two tables (Customer, PuchaseOrder) is used to query by a financial quarter, grouping all the similar references, and then a record count applied in a second query counting the number of records returning results.

    The problem I am having is that regardless of a value (-1 or 0) the record is counted unless each box is unchecked. I have tried putting ' <>0' in the criteria box of the count but this does not work. Other than writing a query for each individual field is there anything I can do?

    Thanks in advance
    Hey dmne05974,

    Can you please post your SQL Statement that you've written so far. It simply sounds like we just need to add a few changes to your SQL Statement, and we should be able to get it to work.

    But without any details, it's really hard to give you a detailed answer.

    Thanks,

    Joe P.

    Comment

    • dmne05974
      New Member
      • Oct 2008
      • 5

      #3
      Joe,

      Solved the problem as i sat down this morning used the textbox controlsource property to action the count on the query, Think it must have been one of those sleep on it problems.

      Thanks for the reply though

      Comment

      Working...