D
Doug VanDerMark
Access 2002
4 Fields, 1 text and 3 yes/no
Group on the text field and count the number of each yes/no fields
individually, the query wizard just adds all 3 yes/no and puts the count in
all 3 yes/no field
Field 2 Field 3 Field 4
Johnson x
Johnson x
Smith x
Johnson x
Smith x
Want to see for totals
Field 2 Field 3 Field 4
Johnson 2 1
Smith 1 1
I am getting
Field 2 Field 3 Field 4
Johnson 3 3 3
Smith 2 2 2
Here is the SQL command
SELECT Table1.Group1, Count(Table1.Field2) AS CountOfField2,
Count(Table1.Field3) AS CountOfField3, Count(Table1.Field4) AS CountOfField4
FROM Table1
GROUP BY Table1.Group1
HAVING (((Count(Table1.Field2))=True)) OR (((Count(Table1.Field3))=True)) OR
(((Count(Table1.Field4))=True))
4 Fields, 1 text and 3 yes/no
Group on the text field and count the number of each yes/no fields
individually, the query wizard just adds all 3 yes/no and puts the count in
all 3 yes/no field
Field 2 Field 3 Field 4
Johnson x
Johnson x
Smith x
Johnson x
Smith x
Want to see for totals
Field 2 Field 3 Field 4
Johnson 2 1
Smith 1 1
I am getting
Field 2 Field 3 Field 4
Johnson 3 3 3
Smith 2 2 2
Here is the SQL command
SELECT Table1.Group1, Count(Table1.Field2) AS CountOfField2,
Count(Table1.Field3) AS CountOfField3, Count(Table1.Field4) AS CountOfField4
FROM Table1
GROUP BY Table1.Group1
HAVING (((Count(Table1.Field2))=True)) OR (((Count(Table1.Field3))=True)) OR
(((Count(Table1.Field4))=True))