Open jscarle opened 3 months ago
Seems related to https://github.com/dotnet/efcore/issues/28393
I confirmed in a different project that there seems to be absolutely no way to configure a User Defined Function in such a way to make it possible to use parameters that are not a C# primitive type such as int, decimal, or string.
Bye
As a follow up to https://github.com/dotnet/efcore/issues/13752, I'm attempting to use
HasDbFunction
with myGeoCoordinate
value object to call the database functionSTDistance
.I already have a value converter as defined below:
The value converter does work when reading and writing entities that contain the
GeoCoordinate
value object. However, when defining the database function as below:The following exception is thrown when the DbContext is instantiated:
It seems that
HasDbFunction
does not take value converters into consideration.Note: This is being developed and tested in .NET 8.0 with EF Core 8.0.