In my case I had to update DistanceBetween function in the edmx file:
<Function Name="DistanceBetween" ReturnType="float" Aggregate="false" BuiltIn="false" NiladicFunction="false" IsComposable="true" ParameterTypeSemantics="AllowImplicitConversion" Schema="dbo">
<Parameter Name="Lat1" Type="float" Mode="In" />
<Parameter Name="Long1" Type="float" Mode="In" />
<Parameter Name="Lat2" Type="float" Mode="In" />
<Parameter Name="Long2" Type="float" Mode="In" />
</Function>
All parameters and a return type should be float
|