Given MS SQL doesn't have a datatype of Collection(Edm.String)
, I'm not sure why they would offer any type of conversion for that datatype, except to support Azure Search only.
That being said in that same code I posted above, add another Global Event to modify the values of the field(s) you're looking to convert.
DocumentCreator.Instance.AddingDocumentValue.Execute += AddingDocumentValue_Execute;
/// <summary>
/// Updating the path to be absoulte vs. relative.
/// </summary>
/// <param name="sender"></param>
/// <param name="e"></param>
private void AddingDocumentValue_Execute(object sender, AddDocumentValueEventArgs e)
{
if (!e.Name.Equals("nodealiaspath", StringComparison.OrdinalIgnoreCase))
{
return;
}
string nodeAliasPath = e.Value as string;
string culture = e.SearchDocument.GetValue("documentculture").ToString().ToLower();
if (string.IsNullOrWhiteSpace(nodeAliasPath))
{
return;
}
e.Value = URLHelper.GetAbsoluteUrl(DocumentURLProvider.GetUrl(nodeAliasPath.ToLowerInvariant(), null, null, culture, null));
}
As you can see by the comment for this event, I'm updating the path to be absolute vs. relative (client requirement to mix with results from other datasources). I'd think you'd be able to get that comma separated value and parse it out into a Collection(Edm.Sting)
in that event. If you're looking for specifics on how to create that collection, you'd have to check the Azure/Microsoft docs for that.