You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Exception when mapping an inherited property in a derived object #56
I have a type B that inherits from type A, and a Property P defined in A.
When I try to map that property in type B, an exception is thrown at the DommelColumnNameResolver, that the key is not present in the entity maps dictionary.
I suggest that instead of using the DeclaringType for the lookup, use the ReflectedType.
Maybe this issue exists in other places too, I haven't checked.
That is indeed a known issue. However, ReflectedType is not available in .NET Standard 1.3 (which Dapper.FluentMap and Dommel) targets. A future version might target .NET Standerd 2.0 which allows us to use RefelectedType again.
Activity
henkmollema commentedon Jul 24, 2017
That is indeed a known issue. However,
ReflectedTypeis not available in .NET Standard 1.3 (which Dapper.FluentMap and Dommel) targets. A future version might target .NET Standerd 2.0 which allows us to useRefelectedTypeagain.henkmollema commentedon Nov 16, 2018
This have been fixed for applications targeting full .NET (e.g. 4.5 or higher) and .NET Core 2.0 and 2.1 in version 1.7.0: NuGet and release notes.
Dapper.FluentMap.Dommel is updated as well: https://www.nuget.org/packages/Dapper.FluentMap.Dommel/1.6.0.
Please re-open or create a new issue if the problem persists.