Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Best way to set up this query

Status
Not open for further replies.

goslincm

MIS
May 23, 2006
292
US
I'm working with a table that has the following structure:

[autono]pk
[quest_num]pk
[quest_yn]
[quest_weight]

The table holds a yes no reply to a series of 15 questions. Each question has a certain weight factor. later.

I need to be able to perform 2 task. The first is to come up with a total score for all questions with a distinct autono. From this, I need need to list for each distinct autono, the question which was answered no to if their score was >10.

This would then bring two other tables:

[apr_id]pk
[quest_name]pk
[quest_text]
[quest_mailout]

and

[autono]pk
[county]
[name]
[date]

I'm not certain how to go about this task.
 
I have read this post a few times, and I am still not sure what you want.

[tt]SELECT [quest_num], Sum(Score) FROM ?? GROUP BY [quest_num][/tt]

Where does score come from? How are the other two tables involved? Can you indicate how they are related?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top