Microsoft Dynamics 365

MultiSelect Option Set Fields in Dynamics 365, v9

In Expert Tips & AdviceLeave a Comment

Microsoft has created a new data type in Dynamics 365 version 9: the MultiSelect Option Set. As the name implies, this data type allows a Dynamics 365 user to select more than one option from a list of option set values. This has been functionality that has been requested for about 15 years, so it’s nice to see it finally arrive.

The relational database purists among us will note that this field completely ignores EF Codd’s normalization rules, which has some interesting implications for what can and cannot be done, with MultiSelect Option Set fields. Those items will be addressed after we revisit the basic mechanics for creating one…

How To Create a New MultiSelect Option Set Field

  1. Navigate to Settings / Customizations / Customize the system (or, best practice, build a new solution in DEV to create this field, and promote the solutions to your other environments).
  2. Expand the Entities folder. Expand the entity you want to create the new field in.
  3. Click on “Fields” and then “New”. The new field form will appear.
  4. Enter the name, and select “MultiSelect Option Set” as the Data Type.
  5. Enter the list of values, as you would with any regular option set. (Note: you can also have a Global MultiSelect Option Set)
Microsoft Dynamics 365

You can then add this field to forms and views as usual. Publish All, and let’s take a look at the CRM UI…

Entering Data into MultiSelect Option Set Fields

When you open a form with a MultiSelect Option Set field, the field shows a “two-line” option set, with the words “Enter text here” displayed, as shown below.

Microsoft Dynamics 365 MultiSelect Option

When you enter the first character into the field, the list of values appears and is filtered by the value you enter. Only the selections that CONTAIN the field value you enter will be displayed. In my example, if I enter “2”, only the “Q2-10” selections appear.

Microsoft Dynamics 365 MultiSelect Option

When you select field values, they appear, surrounded by a box, in the field value area, as shown below.

Microsoft Dynamics 365 MultiSelect Option

When you tab away from the field and save the record, the selections you made will appear in the field, in alphabetical order, separated by semi-colons.

Microsoft Dynamics 365 MultiSelect Option

Some Interesting Limitations & Caveats

As mentioned above, this MultiSelect Option Set field is unique in CRM, as it contains multiple pieces of information. There are several interesting limitations and caveats with these fields.

  1. One word of caution: if you open an existing record, change a selected value in a multi-select option set field, and then click the ‘down arrow’ at the top of the form to move to the next record in the view, the value you entered IS NOT SAVED. You must move away from the field in order for it to save with the down arrow…
  2. You can’t SORT on a MultiSelect Option Set field by clicking on the column header. The MultiSelect field also does not show up in the list of fields on the “Configure Sorting” page in Advanced Find a View Creation, so there is no way to sort on a MultiSelect Option Set field within CRM.
  3. Fortunately, you can filter. You can select one or many values in your filter. You can also select the “Contains No Data” selection to find those records with NO selection in the MultiSelect Option Set field.
  4. Microsoft Dynamics 365 MultiSelect Option

    Under the Custom Filter selection, you can also use the “Contains Values”, or much more importantly, “Does Not Contain Data” filter, which appears to be a new filter operator value just for MultiSelect Option Sets. Using this operator you can find the records that don’t contain one of the (one or many) selections you have made.

    Microsoft Dynamics 365 MultiSelect Option
  5. Unfortunately, you can’t seem to use a MultiSelect option set in a Business Rule.
  6. You can’t bulk edit a MultiSelect Option Set field (realistically, how could you possibly do that reliably, when records could have different values?)
  7. You can’t set a MultiSelect Option Set field through a workflow… (again, can see why, although it would be nice to have an “add to” MultiSelect field option, or a “delete from” MultiSelect Option).

In short, there are some business use cases where the MultiSelect Option Set field could be beneficial. To see a comparison of option sets and lookups, see the next article in this series: Comparing Lookup Fields to Global, Regular, & MultiSelect Option Sets

Leave a Comment