Displaying combined data from rsform submissions 10 Years, 11 Months ago
|
Karma: 0
|
Hello,
Firstly, I am a complete SQL novice.
I am using ari data tables and I have a rsform on my site and am trying to display the submissions, but only the combined data for specific fields. So I want to:
1. Only show certain column, not columns like submit, captcha etc.
2. I have questions with answers "choose 1,2,3,4 or 5". I want to display the combined figure of all the submissions, not each submission's answer. So I need the graph to show that 3 users answered question 1 with a 4, and 2 users answered with a 3 etc.
3. I also want to create a pie chart for each answer showing the percentages of each answer, i.e. Question 1 - 1:20%, 2:26%, 3:12%, 4:30%, 5:12%
This is the sql query I currently have in place:
SELECT
SubmissionId,
FieldName,
FieldValue
FROM
#__rsform_submission_values
WHERE
FormId = 3
ORDER BY SubmissionId DESC, FieldName ASC
Thanks,
Chris.
|
|
|
Last Edit: 2013/12/04 03:13 By chrisreeves.
|
|
Re:Displaying combined data from rsform submissions 10 Years, 11 Months ago
|
Karma: 760
|
Hello,
It is possible to show data from "RS Form" extension with help of "ARI Data Tables" extension. You can read about it here.
Regards,
ARI Soft
|
|
|
|
|
Re:Displaying combined data from rsform submissions 10 Years, 11 Months ago
|
Karma: 0
|
Hello,
Thanks for the reply. I had seen this discussion and followed it to get the sql query I am using. However it doesn't discuss any of the elements I have asked about. I have worked out how to hide unwanted columns using the column settings. But still need assistance on the following 2 points.
1. I have questions with answers "choose 1,2,3,4 or 5". I want to display the combined figure of all the submissions, not each submission's answer. So I need the graph to show that 3 users answered question 1 with a 4, and 2 users answered with a 3 etc.
2. I also want to create a pie chart for each answer showing the percentages of each answer, i.e. Question 1 - 1:20%, 2:26%, 3:12%, 4:30%, 5:12%
This is the sql query I currently have in place:
SELECT
SubmissionId,
FieldName,
FieldValue
FROM
#__rsform_submission_values
WHERE
FormId = 3
ORDER BY SubmissionId DESC, FieldName ASC
Thanks,
Chris.
|
|
|
|
|
Re:Displaying combined data from rsform submissions 10 Years, 11 Months ago
|
Karma: 760
|
If you want to select only specific fields, add the following code to "WHERE" clause:
FieldName IN ('field1', 'field2', 'field3')
Where 'field1', 'field2', 'field3' are names of required fields. It will look like:
SELECT
SubmissionId,
FieldName,
FieldValue
FROM
#__rsform_submission_values
WHERE
FormId = 3
AND
FieldName IN ('field1', 'field2', 'field3')
ORDER BY SubmissionId DESC, FieldName ASC
For other questions, contact RS Form support so they provide queries for their extension.
Regards,
ARI Soft
|
|
|
|
|
|