I have a project to develop an online survey system. I'm worried about how I'll get the answers to the questions to show on a chart. Each chart is each question being analyzed. Let's see, if I have a question that has 4 different answers, and that each question, only one answer can be marked. Basically, the structure would be:
1) pergunta um
a) questao um
b) questao dois
c) questao tres
d) questao quatro
e) questao cinco
2)
a) questao um
b) questao dois
c) questao tres
I need help to define the best criteria for storing these responses in the database. Basically, I need to know how many times in question 1, a, b, c, d, and, was selected to be shown the graph of question one. If I had a table in the following structure:
id_usuario 2
respostas ac
In this case user id 2 would have answered question 1, letter a and question 2, letter c. But the point would be, if I treated this in programming it would be too much work for me. I would like to know how best to develop this system by following these criteria.