Using maths functions in embeded data | XM Community
Solved

Using maths functions in embeded data

  • 26 February 2019
  • 2 replies
  • 7 views

Badge +2
Hello,

In our survey we will ask for participant ethnicity, and then branch to show only 2x of 7 specific ethnicity blocks in order of priority (for ethnicity A,B,C,D,E,F,G), and a catch-all ethnicity block (for ethnicity H to Z).

E.g. If a user identifies that they are ethnicity (A,C,M), they would only see blocks (A,C). If a user identifies (C,P,Q) they would see block (C) and the catch-all.

I've been trying to identify a good logic solution and I thought about incrementing an embedded field (Ethnicity_count). I would like to use maths operations in the survey flow, but I've not been able to get it working using the following:

set embeded data ${e://Field/Ethnicity_count} = 0

IF ethnicity = (A)
THEN show block (A)
AND set embeded data ${e://Field/Ethnicity_count} = ${e://Field/Ethnicity_count + 1}

Does this work in Qualtrics? Can anyone give me some tips, or another solution?

I've tried unsuccessfully with Quotas, and I believe that quota's are more aimed at data across all participants, not individual participants.

Thanks
Dan
icon

Best answer by dan_archer 26 February 2019, 21:24

View original

2 replies

Userlevel 7
Badge +33
Incrementing the counts will work , you can keep track of updated count for branching.
Badge +2
Thanks, I finally got it working after I realised a mistake in my syntax and missing the e from $e

Was using: ${e://Field/Ethnicity_count + 1}
But should be: $e{ e://Field/Ethnicity_count + 1 }

Leave a Reply