Wednesday, 9 September 2015

data - How to convert WKB to WKT?


how can i convert wkb to wkt form ...


i stored coordinates in wkb but now can it will display to use in wkt form



Answer



If you want to use PostGIS to do the conversion, you can choose from the following functions:


bytea WKB = ST_AsBinary(geometry);
text WKT = ST_AsText(geometry);

geometry = ST_GeomFromWKB(bytea WKB, SRID);
geometry = ST_GeometryFromText(text WKT, SRID);

More: http://postgis.net/docs/manual-1.5/ch04.html#OpenGISWKBWKT


No comments:

Post a Comment

arcpy - Changing output name when exporting data driven pages to JPG?

Is there a way to save the output JPG, changing the output file name to the page name, instead of page number? I mean changing the script fo...