-
Type:
Improvement
-
Resolution: Unresolved
-
Priority:
Unknown
-
None
-
Affects Version/s: 3.2.1
-
Component/s: Linq
-
None
-
None
-
Dotnet Drivers
-
None
-
None
-
None
-
None
-
None
-
None
The LINQ translator checks that all items in an array are serialized the same way by verifying that they are all serialized using the same serializer. But this approach doesn't account for polymorphism.
Given the following classes:
public sealed class C { public int Id { get; set; } public Cat Cat { get; set; } public Dog Dog { get; set; } } public abstract class Animal { } public sealed class Cat : Animal { } public sealed class Dog : Animal { }
The following query should work (but currently an exception is thrown):
var queryable = collection.AsQueryable() .Select(x => new Animal[] { x.Cat, x.Dog });
- blocks
-
EF-192 ReloadAsync throws ArgumentNullException
-
- In Progress
-