Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

How can generate a report vi SQL ?

  • darioc
  • darioc's Avatar Topic Author
  • Offline
  • New Member
  • New Member
More
7 years 8 months ago #139341 by darioc
How can generate a report vi SQL ? was created by darioc
How can I generate e report via SQL ?

I need to have in one line all the answers and one token and on the headers the complete questions and not the code.

it is possible to do in some way ?

thanks in advance
The topic has been locked.
  • Joffm
  • Joffm's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
7 years 7 months ago #139475 by Joffm
Replied by Joffm on topic How can generate a report vi SQL ?
Hi, darioc,
of course it is possible.
Even if I find it a bit difficult to start.

I assume you have access to the server and knowledge in SQL.
Well, first analyse the structure of the limesurvey tables.
Some important ones:
"survey_[SurveyID]" (This table contains all answers, but no question text an no answer option text, only the codes)
"groups" (This table contains all groups by SurveyID.
"answers" (This table contains all answer options by QuestionID)
"questions" (This table contains all question texts by QuestionID, SurveyID, GroupID)
"tokens_[SurveyID]" (This table contains the participants)

Now with some Joins in SQL you should be able to create your report.

Best regards
Joffm

Volunteers are not paid.
Not because they are worthless, but because they are priceless
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose