Convert Geometry from T-SQL to PostgreSQL

ruben00000
 
on Aug 08, 2021 11:17 PM
289 Views

how to convert geometry with float x and y sql server to postgress sql

declare 
@x float = 1067527872,
@y float = -234636443,
@p1  geometry
set @p1 = geometry::STGeomFromText('POINT(' + STR(@x,12,7) + ' ' + STR(@y,12,7) + ')',4326)
select @p1 as geom


 

Download FREE API for Word, Excel and PDF in ASP.Net: Download
dharmendr
 
on Aug 08, 2021 11:30 PM