Welcome to the LimeSurvey Community Forum

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

carry forward a name form a previous question to a subsequent question

  • wilverley
  • wilverley's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
8 years 9 months ago #121721 by wilverley
I am very new to lime survey, from reading the manual I understand that I can use answers from previous questions in subsequent questions but can not work out how to do it. What I have is a question that asks 6 people what their first and last names are. later on I want to ask how they are related to one another so I would like my question phrased like this.
Q. How is (person 2 first name) (person 2 second name) related to (Person 1 first name) (person 1 second name)

How is (person 3 first name) (person 3 second name) related to (Person 1 first name) (person 1 second name)
How is (person 3 first name) (person 3 second name) related to (Person 2 first name) (person 2 second name)
Etc etc for all of the six persons
I will use a drop down for the choices
Can someone explain very simply how I insert the names into the question please
The topic has been locked.
  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
8 years 9 months ago #121733 by holch
This is quite easy to do, but what I don't understand is, where and how you use the dropdown. For the choices of the relation? Then it doesn't matter to the solution.

What matters is how you ask the respondent about the first and last name of these 6 people, because the question type is important to know, when you want to access previous responses.

You can do this via the expression manager, usually via curly brakets and the respective response code. Let's assume that the first name of person 1 is stored under the question code Q1first, then you should be able to access the persons name via {Q1first}.

I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.

The topic has been locked.
  • holch
  • holch's Avatar
  • Offline
  • LimeSurvey Community Team
  • LimeSurvey Community Team
More
8 years 9 months ago - 8 years 9 months ago #121734 by holch
I made a quick example question. I think it should help you to get the rest running.

I used an array(text) question to ask for the first and the last name of 3 people.

Then in the next question (a normal array question with the dropdown mode switched on in the advanced settings).

Within the subquestion text I referenced the responses given in the first question. The structure of the code is like this:
{questioncode_subquestioncode_answeroptioncode}.

I answer at the LimeSurvey forum in my spare time, I'm not a LimeSurvey GmbH employee.
No support via private message.

Last edit: 8 years 9 months ago by holch.
The following user(s) said Thank You: DenisChenu
The topic has been locked.
  • wilverley
  • wilverley's Avatar Topic Author
  • Offline
  • Junior Member
  • Junior Member
More
8 years 9 months ago #121751 by wilverley
Ah all becomes clear thank you very much for your help that is exactly what I wanted
The topic has been locked.

Lime-years ahead

Online-surveys for every purse and purpose