Changing custom field type free text to multi select

Paranthaman Sriramulu February 16, 2014

How would be the best approach from you side for below change.

Custom Field Customer needs to be a multi-select dropdown rather than free form text. This will allow us to create portlets with "Customer" as one of the fields.

There are a number of aspects to this task:

data cleanup of existing records. For example, some tickets have custom field values as VZ, Vz or Verizon. All of these must be cleaned up.

how the migration will deal with tickets that have multiple customers in the free text field

1 answer

0 votes
Nic Brough -Adaptavist-
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
February 16, 2014

Not a chance of doing this automatically, you're going to need to do it by building specfic scripts and/or manual work.

I would:

  • As you say, you should first analyse your data to work out what the Customer options should be
  • Rename the old customer field to something like "Customer (deprecated)"
  • Add the new customer field with your new list
  • And now the manual bit - build a search for each customer target. For example "Customer (deprecated) ~ VZ or Customer (deprecated) ~ Verizon" will find the example you've given. Once you've got a moderately accurate list, use "bulk edit" to set the new field. I'd also blank out the old one as a housekeeping exercise, and to make it clear it doesn't need migration any more.
  • Repeat for each customer target field.

Beware though - bulk edit *replaces* fields, so if you have two customers like, say, BP and Shell, you need to have *three* filters and three passes through the bulk edit - one for BP, one for Shell and one for BP and Shell (because if you set BP on issue 1, and then use bulk edit to try to "add" Shell, it will overwrite BP, not add it)

Suggest an answer

Log in or Sign up to answer