SQL query construction

B

blake7

Hi, I have a table as below and I want to create a query to count the fault
type against the product, I have shown below how i want the query to return
the findings etc, can anyone help. Thanks in advance

PRODUCT FAULTY TYPE
iron customer complaint
television ok
telephone warranty
iron internal issue
iron health & safety
iron ok
iron warranty
iron ok
iron internal issue

what I want
PRODUCT FAULT TYTPE TOTAL
iron customer complaint 1
ok 2
internal issue 2
warranty 1
health & safety 1
 
J

Jeff Boyce

Based on your description, it looks a little like you could use a totals
query, grouping on the "type" and counting the records. Check Access HELP
for "totals query".

By the way, none of your example records are simply "ok", so how are you
getting "ok 2"?

--
Regards

Jeff Boyce
www.InformationFutures.net

Microsoft Office/Access MVP


Microsoft IT Academy Program Mentor
http://microsoftitacademy.com/
 
B

blake7

Hi Jeff, thnaks for the reply
I think the way the table info looks when you post it in here changes, below
i have done it again, there are two instances were 2 x "ok" appear in the
fault column against "iron", would you be able to steer me with a little more
info on how to assemble the query ? Thanks Tony

PRODUCT FAULT TYPE
iron customer complaint
television ok
telephone warranty
iron internal issue
iron health & safety
iron ok
iron warranty
iron ok
iron internal issue


what I want

PRODUCT FAULT TYPE TOTAL
iron customer complaint 1
ok 2
internal issue 2
warranty 1
health & safety 1
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top