In KX13 and below, when you performed a join (Source
) using the InfoProvider classes, the joined data was returned with the TypedResult
and you could access it.
In Xperience by Kentico, if you map to the TypedResult (ex GetEnumeratedTypedResultAsync()
), that data is now scrubbed and not available.
example:
var items = await _mediaFileInfoProvider.Get()
.Source(x => x.InnerJoin<MediaLibraryInfo>(nameof(MediaFileInfo.FileLibraryID), nameof(MediaLibraryInfo.LibraryID)))
.Columns(nameof(MediaFileInfo.FileName), nameof(MediaLibraryInfo.LibraryDisplayName))
.GetEnumerableTypedResultAsync();
// KX13 and below this works
items.First().GetStringValue(nameof(MediaLibraryInfo.LibraryDisplayName), string.Empty);
// Xperience by Kentico this no longer returns
items.First().GetStringValue(nameof(MediaLibraryInfo.LibraryDisplayName), string.Empty);
Common use cases were to join on a Foreign Key ID field to the actual referenced entity so you could retrieve additional data.
(rhetorical question as I am going to answer with the answer), how do you retrieve this data in Xperience by Kentico?