I encountered the following problem while attempting to convert an old project from Linq2Sql to EF6.
This project is multilingual (each text has more than one translation), and the database structure is as follows:
How can I retrieve every instance of ExampleEntity1 with every LocalizedContent record filtered by the current language id?
Using the code below, I can load all ExampleEntity1 objects with all LocalizedContent records:
dc.ExampleEntity1.Include(ee => ee.TextEntry.LocalizedContents);
In Linq2Sql I can filter LocalizedContent records using
however, I am unable to discover a fix for EF6.
I'm simply curious as to whether there is a solution for EF6 after seeing similar old inquiries that were posted about 2-3 years ago. The fact that I have dozens of entities in the project and don't want to construct custom objects for each select query makes it a crucial feature for me.
Also discovered was EntityFramework. Although the DynamicFilters nuget package can solve my problem, if at all possible, I would prefer to use "native" EF6 capability.