THIS IS ARCHIVED DOCUMENTATION
Multi-Value Field - Migrating from On-Premises to Cloud Version
Multi-Value Field - Migrating from On-Premises to Cloud Version
Description
If you have a custom component or custom code which uses a multi-value field, you can experience some issues on your page when migrating your Coveo for Sitecore installation from a On-Premises to a Cloud edition.
Environment
- Coveo for Sitecore
- Troubleshooting
- Migration from On-Premises to Cloud version
- Multi-value field
Explanation
This occurs due to the fact that the Search API has changed the format it returns the multi-value field value. The On-Premises version used to return one string with the values separated by semicolon. Now on the Cloud version it’s an array of strings. The following example shows the difference between both versions.
- On-Premises:
"value1;value2"
- Cloud:
[ "value1", "value2" ]
Resolution
To fix this issue, you need to change your code which was splitting the value by semicolon to handle the value returned by the Search API as an array of strings instead.