Check out the LimeSurvey source code on GitHub!
Welcome, Guest
Username: Password:

TOPIC: List of variable names and their related questions

List of variable names and their related questions 4 years 1 month ago #87609

  • tfj
  • tfj's Avatar
  • Offline
  • Expert Lime
  • Posts: 80
  • Thank you received: 6
  • Karma: 5
I am using the Expression Manager more, particularly for Equation-type questions. I haven't figured out an easy way to determine the proper variable name for a particular question/answer that I need in an equation.

For now, I have been setting up a condition using the question I need, looking at the resulting condition in the Relevance box for the proper variable name, then deleting the condition. I realize this is not ideal.

When I run a print-out of the survey, I can get a somewhat close approximation of what the variable name should be, but not close enough to use.

Can anyone suggest a more efficient way to determine variable names and their related questions?

I am using version 1.92+, Build 120919.

Thanks.

tfj
The administrator has disabled public write access.

List of variable names and their related questions 4 years 1 month ago #87643

  • tfj
  • tfj's Avatar
  • Offline
  • Expert Lime
  • Posts: 80
  • Thank you received: 6
  • Karma: 5
To clarify my previous post with an example, let's say that you are using an "Array dual scale" question type. It isn't enough to reference the question in an equation merely with the Question Code. When referencing one part of the question (for instance, the first scale), you would need to reference "AnswerCode_SQ001_0.NAOK."

Other answer types require different references.

Thanks!

tfj
The administrator has disabled public write access.

List of variable names and their related questions 4 years 1 month ago #87646

  • mdekker
  • mdekker's Avatar
  • Offline
  • LimeSurvey Team
  • Posts: 344
  • Thank you received: 68
  • Karma: 38
Did you try the survey logic file? It is in the menu with the paper sheet and a pencil (survey properties) and is the last item in the list.
---
Menno Dekker
The administrator has disabled public write access.

List of variable names and their related questions 4 years 1 month ago #87649

  • tfj
  • tfj's Avatar
  • Offline
  • Expert Lime
  • Posts: 80
  • Thank you received: 6
  • Karma: 5
mdekker:

Thank you for the suggestion. I have been using the Survey Logic file constantly since it first came out -- it is a great and useful debugger.

It did not occur to me to use it for the purpose of determining variable names, but after looking at it again, I can see how it is almost what I was looking for. I will just need to assemble the variable names from the components listed.

Thank you, again!

tfj
The administrator has disabled public write access.

List of variable names and their related questions 4 years 1 month ago #87676

  • DenisChenu
  • DenisChenu's Avatar
  • Offline
  • Moderator Lime
  • Posts: 9555
  • Thank you received: 1374
  • Karma: 390
tfj wrote:
For now, I have been setting up a condition using the question I need, looking at the resulting condition in the Relevance box for the proper variable name, then deleting the condition. I realize this is not ideal.
I use same workaround :whistle: .

Or i use LimeReplacementField (popu editor mode) to copy/paste the code :side:

Denis
Assistance on LimeSurvey forum and LimeSurvey core development are on my free time (Need support ?).
A bug not reported is a bug not corrected. | 2.61lts version improved | Need plugins for LimeSurvey ?
The administrator has disabled public write access.
Time to create page: 0.237 seconds
Imprint                   Privacy policy         General Terms & Conditions         Revocation information and revocation form