The new Microsoft Dynamics 365 July 2017 Update introduces multiple features and UI enhancements, including the highly requested multi-select option set field. It provides the user a pick-list of options, with the ability to select multiple option set values which you could not do with an option set.
The field control itself already has a lot of interesting abilities. If you have a long list of values, and scrolling up and down is a hassle, the user can search for option values through text search on the field control. Adding and deleting pick-list option values for the field are also intuitive within a container for selected values, and the pick-list of option values.
This feature gives Dynamics 365 designers and customizers the ability to define selectable defined values (as such with an option set), but with the freedom of selecting and storing multiple values. By simply selecting ‘MultiSelect Option Set’ as the data type when defining your fields, the field will render on the form as a multi-select control.
For views on the landing side, there are also custom controls for filtering multi-select option set fields. This is so that you can filter data on views on whether they contain specific option values. The filtering control looks similar to how the selectable field appears on the form, where it is a tick-untick pick-list control.
In Advanced Find, the multi-select option set field has custom operators for view filtering. Most notable of this is the ‘Contain Values’ operator which selects records which contain the values specified. This gives the option of a broad match to filter down records. Exact matches are of course available with the ‘Equals’ operator.
One thing to note about multi-select option sets in views and Advanced Find is that you cannot use the multi-select option set field for sorting. This would make sense considering the data type, and the potentially vast number of combinations the field could have in terms of selected option values. The order of appearance of the option set values on the field depends entirely on what order you select the values. The screenshot below shows how the field and field values for multi-select option sets would appear in a view in Advanced Find. The option ‘Milk’ was selected first by the user, and thus appears first in the field, followed by the option ‘Eggs’ and so on.
The screenshot below shows how the multi-select option set values would appear if you use the Export to Excel functionality for this view:
Global option sets are a list of defined options which can be reused in any entity and in any option set type field. This functionality would depend on how we define our field settings. To demonstrate this example, I’ve defined a multi-select option set called ‘Connection Category’ on the same Contact form, and selected ‘Use Existing Option Set’ = Yes. This will allow the use of global option sets for multi-select option set fields. I’ve then selected the out-of-the-box global option set ‘Category’ for the Connection entity. The screenshot below shows this field configuration, as well as the available option set values for the Category global option set.
There would be no difference in how the data is stored and presented when comparing local and global option sets for multi-select option set fields. Again, do note that the order of appearance of the option set values on the field depends entirely on what order you select the values.
When making charts for multi-select option sets, there are limited available aggregates when having the field in Legend Entries. It is not available as a Horizontal (Category) Axis Label.
It is not possible to drilldown charts for multi-select option set fields.
It will be interesting to see the possible ways developers can configure business requirements with what the multi-select option set can offer in the upcoming future. How the option set values can be selected and de-selected according to business logic, and how you can filter option set values accordingly can further increase the potential application of this feature. Important to also tie in with the new multi-select option set feature are the changes to the client-side APIs (notably Xrm.Page and Xrm.Utility) with the replacement client-side APIs. Developers will need to adjust accordingly to the new developer tools Microsoft has released for the July 2017 update, especially since client-side scripting is important with manipulating option set fields and option set values.
Multi-select option set fields is an exciting feature that Microsoft has introduced, and is one of the few exciting features in the Dynamics 365 July 2017 Update. I hope this blog gives you a helpful introduction to multi-select option set fields, its current functionality, and food-for-thought on its potential application in the future with building smarter CRM applications.