How to use IF functions as an embedded data field? | XM Community
Skip to main content
Solved

How to use IF functions as an embedded data field?


Hi, I would like to set an embedded data field which takes into account one of the survey participant's previous answers. In Excel, I would create this function: if(PreviousAnswerX=20, 20, 0). This says that if the participant's answer to question X was 20, the embedded data field should be set to 20. Otherwise, the embedded data field should be 0. Is there a way to create such a function in Qualtrics? Thanks so much!

Best answer by PeeyushBansal

Initially set your embedded variable equals to 0 at top of survey flow. Later apply branch logic and set same variable within branching equal to 20
View original

3 replies

Akdashboard
Level 4 ●●●●
Forum|alt.badge.img+6
  • Level 4 ●●●●
  • 488 replies
  • October 1, 2018
In the survey flow, you need to apply branching logic using branching elements (where you put in the question logic you want, like if Q1 = 20), then nest an embedded data element in the branch element. Easy peasy.

  • Author
  • 1 reply
  • October 1, 2018
Thanks! This is very helpful. I use this logic quite often and hoped to find a simple, dynamic formula to create a calculated field. This way, I could avoid creating dozens of branches and embedded data fields in the survey flow. But this works well too, thanks again!

PeeyushBansal
Level 6 ●●●●●●
Forum|alt.badge.img+39
  • Level 6 ●●●●●●
  • 1148 replies
  • Answer
  • October 1, 2018
Initially set your embedded variable equals to 0 at top of survey flow. Later apply branch logic and set same variable within branching equal to 20

Leave a Reply