MS Access query question ...

Discussion in 'Computers' started by Ted Lee, Aug 17, 2005.

  1. Ted Lee

    Ted Lee Lead Actor

    Joined:
    May 8, 2001
    Messages:
    8,390
    Likes Received:
    0
    Trophy Points:
    0
    hi all -

    what i'm trying to do is count the number of times a particular value (in this case a team name) shows up in a data table (#1) that i've imported.

    so, if "team a" shows up 10 times, and "team b" shows up 83 times, etc ... i need access to give me that info.

    i think it's the "count" function that does it, but i'm not sure how to design the query.

    ----

    additionally, i have another data table (#2) with all the possible teams listed. i would like to have a query that would show me what teams are *excluded* from data table #1? so, if "team z" and "team r" aren't in data table #1, i would like to know that as well. on this one, i have no clue what function to use.

    -----

    thanks!
     
  2. MarkMel

    MarkMel Screenwriter

    Joined:
    Nov 19, 2003
    Messages:
    1,875
    Likes Received:
    116
    Trophy Points:
    1,610
    You can use the summing function of the query. Press the summing button. Add in your fields. Under the team name field on the total line in the query builder where it currently says 'Group By', select the count option.

    That should do it for you.

    For your part II, In the query menu, click 'new' and then select find unmatched query wizard and walk thru the steps. That will get you what you want.
     
  3. Ted Lee

    Ted Lee Lead Actor

    Joined:
    May 8, 2001
    Messages:
    8,390
    Likes Received:
    0
    Trophy Points:
    0
    thanks mark! i got the second part (unmatched query wizard) to work. [​IMG]

    edit: i got the first one to work finally. i was trying to add all the columns, instead of just the one i wanted grouped. go figure. :b
     
  4. MarkMel

    MarkMel Screenwriter

    Joined:
    Nov 19, 2003
    Messages:
    1,875
    Likes Received:
    116
    Trophy Points:
    1,610
    No prob, I design Access DBs all day so it was simple to explain.
     

Share This Page