How to create embedded data field based on completion date? | XM Community
Skip to main content
Question

How to create embedded data field based on completion date?

  • June 5, 2025
  • 1 reply
  • 44 views

Forum|alt.badge.img+2

I want to add a data field to my survey that’s based on the completion date of the participant.

Basically, my survey start on day X, so I want to code a data field that tells me if a participant has responded on day 1, day 2, day 3 etc.

 

I thought I could maybe just create a survey flow where I create an embedded data field which I’m applying some logig to, e.g. “if completion date < [dd/mm/yyyy], then day = 1” and so on. However, I realized that the completion date of course is not yet available DURING the survey.

 

So is there any option I can already automatically create such a recoding “script” to my survey?

1 reply

vgayraud
QPN Level 6 ●●●●●●
Forum|alt.badge.img+58
  • QPN Level 6 ●●●●●●
  • 549 replies
  • June 5, 2025

Hi,

You could use a workflow triggered on survey completion with a code task to compute the day, followed by a web service task in which you would call the update response API to send back the value to an ED field in your original response.