Mapping between question codes and question headings

More
5 years 2 months ago #79936 by rstec
rstec created the topic: Mapping between question codes and question headings
Hello! ;)

The question I have is this one: I need to map the question codes with the question headings, for example in the survey_89541 I have one column with this heading: [89541X1X34] and I need to map it with the full question, that in this example would be: Where were you born? so the map would be [89541X1X34] => Where were you born?

I need the database query in order to do this ==> select * from survey_89541 inner join ....... (this is what I don't know) :unsure:

I know that when you export the results you can change between question codes, abbreviated questions, full headings and export it to CSV, Excel, etc. But I need to work directly from the database, this because I am using a report tool, and in order to define the reports, I need to specify the database query on which this report will work on.

I know limesurvey does it in the file exportresults.php but I couldn't find how, any help will be fully apreciated. :)

Thank you!

Please Log in to join the conversation.

More
5 years 2 months ago #79952 by Mazi
Mazi replied the topic: Mapping between question codes and question headings
Have a look at the createfieldmap function. If you let Limesurvey create the fieldmap, the related array should contain all information you are looking for.
For more complex surveys this is a far easier approach then querying all the data manually.


Best regards/Beste Grüße,
Dr. Marcel Minke
(Limesurvey Head of Support)
Need Help? We offer professional Limesurvey support
Contact: marcel.minke(at)survey-consulting.com'"

Please Log in to join the conversation.

Did you already participate in our customer survey?

Don't miss your chance for great prices.

Please click here to participate:

Start now

Start now!

Just create your account and start using Limesurvey today.

Register now