How to safely update a form mid-survey

You programmed your form, tested it, made some changes, tested it again, and felt confident that it was ready to go to the field. You trained your surveyors, they’ve scattered across the country, and the data is rolling in. And then… you realize that despite all the testing you did, you still need to make some changes to your form. But you already have data collected with the existing version.

Luckily, SurveyCTO is quite robust when it comes to updating a form and allowing data from all of your form versions to coexist in one place, but there are changes that can cause problems down the line (like missing data) and it’s better to avoid making them in the first place. What follows is a list of the most common changes you might make to a form after it’s already underway and the quick do’s and don’ts for each scenario. For a comprehensive, detailed discussion beyond this quick, actionable advice, read the topic on updating an existing form.

First, let’s go over common changes you can make that you don’t have to worry about. We can call these “safe” changes.

Safe changes

Making changes globally

A field name appears in many places in a form definition. For example, whenever that field’s value is used in relevance, constraints or in any other type of expression, that field’s name is present, to call that value. If you want to do things like change the name of a field or group, or modify values in a choice list, you’ll want to make those changes globally, so every reference to that field is modified accordingly.

The online form designer’s search functionality will allow you to do this. You might also make shorter work of such changes in Excel or Google Sheets using ‘find and replace’. Export your form from the server if need be, to Excel format and edit. You’ll be able to upload the form definition from the Design tab of the server console, to update the same form and continue editing online if you choose.

Read below to fully understand how to safely rename a field or group, change choice list values, or delete choice list items and more.

Changes that require extra care

1. You want to remove a field from the form 

  • DON’T delete the field from your form.
  • DO give the field a relevance of ‘0’. This way, the field will never appear when the form is used, but the data that was already collected using this field will still exist in the dataset.
  • ALSO check the rest of the form for references to this field, particularly the relevance, constraint, and repeat count columns. Since this field will always be blank from now on, make sure that other parts of your form don’t depend on it having a specific value.

2. You want to change the name of a field 

  • DON’T change the name of an existing field. SurveyCTO will interpret this as deleting the original field and adding a new one, and any data you already collected in the original field won’t show up in later exports.
  • DO give the original field a relevance of ‘0’. Then, create a new field with the correct field name. Your output will contain data from both fields, which you can combine during data cleaning.
  • ALSO make sure that you update any constraints, relevances, repeat counts, and calculate expressions to reference the new field name and not the old one. See the above advice about making changes globally, for an idea on how best to approach the edits you need to make.

3. You want to move a field into a group when it is not already inside one 

  • DON’T just move the field inside a group.
  • DO give the original field a relevance of ‘0’. Then, create a new field inside the group with a different field name from the original (it can be similar, but don’t make it exactly the same). Your output will contain data from both fields, which you can combine during data cleaning outside SurveyCTO.

4. You want to move a field out of a group when it is already inside one 

  • DON’T just move the field outside of the group.
  • DO give the original field a relevance of ‘0’. Then, create a new field outside the group with a different field name from the original (it can be similar, but don’t make it exactly the same). Your output will contain data from both fields, which you can combine during data cleaning.

If you have already moved a field outside of its original group and kept its name the same, this is OK. If you use SurveyCTO Desktop to export your data, there is an option in the preferences to “Ignore groups” on export, which will combine data from both versions of the field that have the same name. This could slow down the speed of your export, somewhat, but sometimes it’s your only option to download a unified set of data if you’ve already made these changes.

5. You want to move a field from one group to another group 

  • DON’T just move the field from one group to the other.
  • DO give the original field a relevance of ‘0’. Then, create a new field inside the group where you want this field to be, with a different field name from the original (it can be similar, but don’t make it exactly the same). Your output will contain data from both fields, which you can combine during data cleaning outside SurveyCTO.  

6. You want to change the name of a group or a repeat group

  • DON’T just change the name of the group or the repeat group.
  • DO give the original group or repeat group a relevance of ‘0’, then copy it and give the copy a new group or repeat name. Modify the field names in the new group slightly.
  • ALSO make sure that you update any references to the old repeat group name inside expressions which have the indexed-repeat() function to reference the new repeat group name and not the old one. See the above advice about making changes globally, for an idea on how best to approach the edits you need to make.

7. You want to remove choices from a choice list 

  • DON’T just delete them (especially if you are using our automatically generated Stata do-files). If you already collected data with the original list, you won’t get labels applied to those values if you remove choices from the list.
  • DO put a choice filter on the choice list. Give the choices that you want to appear a filter value of 1, and the choices you don’t want to appear a filter value of 0. Then, use the following expression as the “choice_filter” for any field that uses the choice list: filter = 1.
  • ALSO make sure that you update any constraints, relevances, repeat counts, and calculate expressions to reference the new values and not the old one. See the above advice about making changes globally, for an idea on how best to approach the edits you need to make. 

8. You want to change the values of items in your choice list 

  • DON’T just change the values (especially if you are using our automatically generated Stata .do files). If you already collected data with the original list, you won’t get labels applied to those values if you change the choice’s values from the list.
  • DO put a choice filter on the choice list. Add any options that need to be different. Give the choices that you want to appear a filter value of 1, and the choices you don’t want to appear a filter value of 0. Then, use the following expression as the choice_filter on the survey sheet for any field that uses the choice list: filter = 1

list

value

label

filter

 

yesno

1

Yes

0

Old value

yesno

0

No

0

Old value

yesno

3

Yes

1

New value

yesno

4

No

1

New value

  • ALSO make sure that you update any constraints, relevances, repeat counts, and calculate expressions to reference the new values and not the old ones. See the above advice about making changes globally, for an idea on how best to approach the edits you need to make.

Do you have thoughts on this support article? We'd love to hear them! Feel free to fill out this feedback form.

0 Comments

Article is closed for comments.