Grouping records

G

Guest

I have a questionaire with ten questions - the answer to each is a separate
field (I.e. Ans_Ques1, Ans_Ques2 etc.) On my report I want to group the
answers where all answers to number 1 are together, all answers to number 2
are together etc. I cannot find a "non-nested" way to group them. Can
anyone help?
Thank you!
 
G

Guest

Leslie said:
I have a questionaire with ten questions - the answer to each is a separate
field (I.e. Ans_Ques1, Ans_Ques2 etc.) On my report I want to group the
answers where all answers to number 1 are together, all answers to number 2
are together etc. I cannot find a "non-nested" way to group them. Can
anyone help?
Thank you!

Well, sorry... but your table structure is improperly normalized. A much
better design is to have one *record* for each answer, rather than one
*field*. Do a Google search for "Duane Hookum Survey" (I don't have the link
handy) for a properly normalized questionnaire design.

Failing that, a UNION query can be used to "string out" your data. Open the
SQL window of a new query and edit it to something like

SELECT <field>, <field>, AnsQues1 FROM yourtable
UNION ALL
SELECT <field>, <field>, AnsQues2 FROM yourtable
UNION ALL

<etc. etc.>

and base your report on this query.
 

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

Similar Threads


Top