morten71 wrote:
is it possible to insert a point into a geography column?
Something like:
StoreEntity store = new StoreEntity()
{
StoreGeo = geography::STPointFromText('POINT(-6.261099 53.339956)', 4326)
}
?
using Microsoft.SqlServer.Types;
var point = SqlGeography.Point(Convert.ToDouble(model.Lat), Convert.ToDouble(model.Lng), 4326);
StoreEntity store = new StoreEntity()
{
LocationGeo = point
};