Math Calculation for Trimming | XM Community
Skip to main content

Math Calculation for Trimming

  • February 22, 2023
  • 3 replies
  • 59 views

Forum|alt.badge.img+2

How to do Math Calculation to trim the existing field value and store as a new embedded data field.
For Example I am having metadata field as External code and value as "1000abc_ Allowance_03172020_012452"
I want to store only this value 03172020_012452 as new field.

3 replies

Deepak
QPN Level 8 ●●●●●●●●
Forum|alt.badge.img+46
  • February 22, 2023

Sathwik
I believe this post should help, you can do this via Javascript and store it back in embedded data
left/right substring extraction functions from piped text? — XM Community (qualtrics.com)
Hope it helps!


Forum|alt.badge.img+2
  • Author
  • February 22, 2023

I want to achieve it through math operations only, not through java script.


Deepak
QPN Level 8 ●●●●●●●●
Forum|alt.badge.img+46
  • February 22, 2023

Sathwik
As mentioned on this support page Math operations do not allow you to strip the string.
"Math operations allow you to create custom values with each response. For example, you can create a function that calculates a formula using scoring for individual participants. Math operations can be performed in the survey flow, within a question, or choice text."
Hence, if you need to achieve something like that as far as I know JS is the route.
Hope it helps!