Wrox Home  
Search P2P Archive for: Go

  Return to Index  

access thread: Count If Function


Message #1 by "Simon Pearce" <pearce64@m...> on Sat, 22 Mar 2003 11:33:43
Dear Group

I have a Form which contains The Following Fields
     E.Hants PCT
PCT ------------------------
                   1                                 2                     
Emergency Backup  ---            AfterSchool          ---
Nursery           ---            Childminder          ---
                                                      3
Childcare         ---            AfterSchoolClub      ---
Holiday           ---            Other                ---

Which produces Data in a Table as below.  The user enters their preference 
for childcare, indicating their First, second & third preference for 
childcare arrangements, represented as 1 or 2 or 3.

                              Childcare Arrangement
                              
PCT Catchment Area	     EB  N CCare Hol AS CM Oth
                             

E. Hants PCT	             1	 2   3
Fareham & Gosport PCT	         1   2	     3
E. Hants PCT	             1	 2	     3
Portsmouth City PCT	     2	     1	     3		

For Eact Childcare Arrangement (I want to Count all the 1st, 2nd and 3rd 
choice preferences broken down by PCT)

example         1st Choice        2nd choice          3rd choice
                 
               EB    = 24             12                 5
E. Hants       N     = 12              8                 2
               Ccare = 2               3                 1
               Hol   = 0               2                 1
               AS    = 5               1                 0
               CM    = 0               5                 0
               Oth   = 0			

It would be very easy to achieve this in Excel using a countIF, but the 
client wants it in Access.  Is it possible to call the Excel CountIF 
function from Access?  Or is there an easier way using a combination of 
crosstabs?





  Return to Index