I want count the result from table.
Table looks like this(row data),
Que is question and answer is Answer, and answer most have a value of 1 to 5, but it can vary depending on the question.(like 1 to 9)
The image above is only part and the question is from 1 to 13. The rows in the table repeat over and over again.
I'd like to know the percentage of answers to each question.
I try to count,
SELECT COUNT(*) FROM survey.surveys WHERE exhibition_id = 2 GROUP BY que;
But this is just count by que
How I can count it?
I want result like,
que | answer | count(answer)
1 | 1 | 30
1 | 2 | 27
1 | 3 | 28
1 | 4 | 31
1 | 5 | 30
2 | 1 | 17
2 | 2 | 23
2 | 3 | 31
2 | 4 | 45
2 | 5 | 29
