Questions tagged [well-known-text]

Well-known text (WKT) is a text markup language for representing vector geometry objects on a map, spatial reference systems of spatial objects and transformations between spatial reference systems.

Filter by
Sorted by
Tagged with
1
vote
1answer
34 views

WKT coordinate inner order (long,lat)

In an open-source tracking project that uses WKT in its API, we have a debate about what is the correct order for representing geographical coordinates. Lat and then Long or Long and than Lat. In most ...
1
vote
1answer
34 views

OpenLayers: Incorrect rendering of WKT

I'm using the draw function of OpenLayers for draw a polygon. I need the wkt from the drawn geometry because I need to send it to PostGIS. <textarea name="name" rows="20" cols="80" ...
0
votes
1answer
13 views

Trouble working with a .TSV containing WKT

I'm working with a .TSV file that represents district boundaries in a portion of a country in Carto. The polygon data is represented in a string column of Well-Known Text lat/long vertices, which I'm ...
1
vote
1answer
66 views

Convert points to line segment

In MySQL, I have two tables to store GPS trackpoint and second table to store chainage values. Lines can have more than one condition. I wish to generate line segments by using both tables above. ...
0
votes
0answers
39 views

Convert list of GML coordinates into WKT

I am working with a NetCDF file. One of the attributes of the file is its footprint given as just a list of GML coordinates e.g. #ncds is a netCDF dataset >>> ncds['METADATA/EOP_METADATA/om:...
0
votes
2answers
44 views

Coordinates of WKT in PostgreSQL

I have a table in PostgreSQL. And it has no X and Y coordinates. But, it has a geom column with the WKT. Also, I have created an empty column called LAT and other called LONG. So, what I want is to ...
3
votes
1answer
112 views

.prj files from ESRI aren't WKT

We are seeing .prj files from our users that don't look like the normal WKT formatted ones we've seen up to this point, instead, they match the format illustrated at "Esri Grid format". When we ...
1
vote
1answer
94 views

Create an ESRI Shapefile from WKT with OGR

I want to create an ESRI Shapefile layer from a CSV file. In my CSV I have several attributes (text, numeric) and geometry in WKT style. I have a problem with the geometry field wich is truncated to a ...
1
vote
0answers
74 views

Write GeoPandas df to PostGIS - Linestring Z geometry

I am trying to write a geodataframe with Linestring Z geometry to a PostGIS table. This rise the error: ProgrammingError: (psycopg2.ProgrammingError) can't adapt type 'LineString' [SQL: INSERT INTO ...
1
vote
0answers
41 views

Generate custom WKT Coordinate System definition from local / WGS84 pairs of coordinates [closed]

I am wondering if it possible to create a custom WKT for coordinate transformations based on pairs of WGS84 lat/lon and the corresponding local N/E values. So like a minimum 2 pairs? If so is it ...
1
vote
1answer
79 views

Check if shapefile Polygon has a valid number of points - Python [closed]

I'm trying to create a polygon from ShapefileReader.shapes() object in python using the shapely.wkt library. But I'm having the followeing error: IllegalArgumentException: Invalid number of points in ...
4
votes
2answers
74 views

Why is a vertical polygon defined by WKT PolygonZ invalid?

Can you tell me, why this PolygonZ is invalid? PolygonZ ((409662 5317369 285, 409662 5317377 285, 409662 5317377 302, 409662 5317369 302, 409662 5317369 285)) The polygon is completely vertical, but ...
2
votes
1answer
63 views

How can I determine if a transformation between two CRS is simply scaling/translating or more complex?

We are using pyproj to transform between coordinate reference systems. What is a good way to check if the transformation is simply scale/translate/units? Basically, I want to know if a grid in the ...
3
votes
1answer
99 views

Pasting more than one geometry at a time in Quick WKT plugin for QGIS

I have a CSV of WKBs that I need to convert to WKT. Can I paste them all into Quick WKT at the same time? How do you break the spaces between geometries? Page break, comma, semicolon, etc. do not ...
1
vote
2answers
201 views

Converting SDE.ST_GEOMETRY polyline to SDO_GEOMETRY with SQL: Why are there so many nulls?

I have a SDE.ST_GEOMETRY polyline FC in an Oracle 18c/10.7.1 geodatabase. I want to convert the SDE.ST_GEOMETRY shape column to SDO_GEOMETRY using SQL. Reason: So that I can do linear referencing ...
0
votes
1answer
130 views

Use PHP form to insert geometry from WKT into SQL Server 2017

I have a PHP 7.3 form that asks the user for a Name, a WKT and an SRID. I would like to upload the WKT and SRID to SQL Server 2017 so that it creates a geometric object in Upload_WKT_Test using ...
0
votes
1answer
82 views

Lat/Long WKT field to line geometry

I'm working with data containing multiple lat/long entries within a single row. I am using PostGreSQL to process the data. Is there a way to take the WKT lat/long field and convert it into a line geom ...
0
votes
1answer
84 views

Using geometry stored in SQL Server table instead of WKT as input to function

I am new to SQL Server, I have a function called STVectorize that takes a geometry and breaks it down into its constituent vectors: SELECT e.[id], e.[element_id], e.[subelement_id], e.[vector_id], ...
1
vote
0answers
86 views

Can't import WKT polygon to SNAP

I have big size Sentinel-1 image and I would like to clip it to smaller size. For that i'm trying to import shapefile but I get errors all the time: This is my polygon WKT: PolygonZ ((102....
1
vote
0answers
93 views

Unknown proj4: how to create custom proj4 from wkt?

I have a shapefile with a .prj file I've never seen before. In fact, it seems that GDAL doesn't even know what it is (see below). Therefore, when I read it into R with raster::shapefile() the CRS isn'...
-1
votes
1answer
134 views

Convert shapefile to WKT [closed]

I have this : poly1 = ogr.CreateGeometryFromWkt(polygons) and error : Traceback (most recent call last): File "C:\PROGRA~1\QGIS3~1.6\apps\Python37\lib\code.py", line 90, in runcode exec(code, ...
4
votes
2answers
812 views

Adding field with geometry WKT in QGIS

I have a shapefile with polygons and want to add an attribute field with the WKT in QGIS 3.4. The function geom_to_wkt in the Field Calculator isn't working and I don't know how to do it. Any ideas?
0
votes
1answer
77 views

Calculate feature extent OpenLayers?

I have a feature created from Well Known Text as following: var feature = format.readFeature(wkt , { dataProjection: 'EPSG:25830', featureProjection: 'EPSG:25830' }); When I add it to a ...
0
votes
0answers
21 views

Converting feature from draw interaction to WKT string

I've problems with converting the feature which I'm getting in draw interaction into the WKT string. I saw multiple examples which looks like it should be simple but I'm always getting the following ...
1
vote
1answer
42 views

Multipolygon in Los Angeles County Parcels Tax Roll

I downloaded the Los Angeles Parcels Tax Roll data into QGIS. I copied the information for a single parcel results in QGIS: wkt_geom OBJECTID_1 AIN Roll_Year AssessorID TaxRateArea ...
2
votes
1answer
66 views

Converting tabular data with multiline string field using FME?

I have data in a table. One of the fields has pairs of coordinates. The coordinate pairs represent a point and the points joined in order to represent a line. The number of coordinate pairs varies. ...
1
vote
0answers
82 views

What could be a proper and simple invalid WKT/WKB geometry?

We are converting a geometry table to another one and we would like to convert every invalid geometry to a single one easily identifiable by users in WKB or WKT form and not breaking the processing or ...
2
votes
1answer
135 views

Convert WKT to image [closed]

Is there any way to convert WKT like MULTILINESTRING ((48.8744070530328 34.71707055692468, 49.127092599907755 34.72892221300337, 48.89363312725153 34.70987407974113, 48.93002533916562 34....
2
votes
1answer
100 views

Shapefile export of holes geometries in QGIS with wrong type MultiPolygon

I want to export a layer with holed geometries in it. But when I save my features to shapefile in QGIS 3 it creates a file with MultiPolygon as geometry type. The fact is that a holed polygon isn't a ...
4
votes
2answers
519 views

PostGIS `COPY` geometry with SRID?

Is it possible to use COPY on a file full of WKT POINTs without dropping the explicit SRID on the destination column? I'm trying to insert several million rows of WGS84 points and am using COPY for ...
1
vote
0answers
64 views

Why coordinates are saved like “0101000020110F00003CDBA337DCC351C06D37C1374D374840” in db? [closed]

On my DB, the data looks like this: In the DAO I am executing a query: public Object login(UserEntity user) { StringBuffer sb = new StringBuffer(); sb.append("SELECT user FROM ...
1
vote
1answer
115 views

Custom projection in GeoServer

I am trying to create a custom projection in GeoServer, but I see nothing (from the logs, neither in the SRS_list) coming out. The projection I'm trying to create is a Mercator for Mercury. I start ...
1
vote
1answer
243 views

Sending geographic data from Postman?

I am trying to create a GIS app using Java, Spring and Hibernate. I send a JSON from Postman like this: { "pointName":"any location", "geom":"POINT(-71.060316 48.432044), 3857" } The JSON ...
0
votes
1answer
167 views

Get GeoJSON or simple WKT from a GPFeatureRecordSetLayer ArcGIS js API

Is it possible to get the GeoJson representation of a GPFeatureRecordSetLayer that is returned from GPServer task? I am able to draw the feature on the map (using the ArcGIS js API) with code like ...
2
votes
0answers
574 views

Implicitly convert Geometry to WKT string in PostGIS

Suppose I have a table defined as follows: CREATE TABLE gtest (name varchar, geom geometry); To insert, I am able to simply do this: INSERT INTO gtest VALUES ( 'Polygon', 'SRID=4326;POLYGON(...
0
votes
2answers
285 views

ST_GeomFromText fails on syntax error inside tuple of coordinates?

I am receiving the following error when trying to execute ST_GeomFromText(wkt) psycopg2.ProgrammingError: syntax error at or near "1187780.76" LINE 1: ...0822.05,(ST_GeomFromTEXT(POLYGON ((...
1
vote
1answer
226 views

Export MultiPolygon data as WKT from QGIS 3

I have the polygon data for the city of Kamloops in QGIS 3. When I try to copy features of this polygon and try to paste it over here: https://arthur-e.github.io/Wicket/sandbox-gmaps3.html I don't get ...
6
votes
2answers
560 views

Convert WKT coordinate reference system to PROJ4

I'm currently working on a better support of LAS 1.4 file format in the rlas R package. In LAS 1.4 format the CRS of the point cloud can be stored as a WKT string. For example this is what I read from ...
2
votes
2answers
279 views

Seeking for a solution to convert GeoTIFF to 3d WKT

I am trying to convert some DEM in .tif image to polygon geometries representing 3 dimensional triangles that is Well-known text (WKT) - 3D (x, y, z) I was able to use SAGA to convert my GeoTIFF ...
1
vote
1answer
99 views

State Plane Scale Factor in WKT

I need to convert an old-style projection file (created with Global Mapper) to a WKT format for use in my GIS program (ArcMap or GDAL or whatever). The problem is that my old-style projection file ...
2
votes
1answer
170 views

What is the history behind WKT and proj.4? [closed]

What is the history behind WKT and proj.4 formats for defining coordinate systems? Does one have advantages over the other? Why do both exist? I'm guessing they were developed independently for ...
1
vote
2answers
113 views

Need to zoom into a vector Layer of a multipolygon

I am getting a multipolygon coordinates from DB in WKT format. I am able show the same on the map. But the problem I am facing is while zooming to center of the Multipolygon. Is there any way to zoom ...
2
votes
1answer
236 views

Getting SRID Well Known Text (WKT) metadata from PostgreSQL?

The SRID metadata is showed by, e.g., this web page: Definition: Well Known Text (WKT) PROJCS["UTM Zone 24, Northern Hemisphere", GEOGCS["GRS 1980(IUGG, 1980)", DATUM["...
2
votes
3answers
999 views

ProjNet. Coordinate reference system transformation deviation

I have a project with C# that contains a CEFSharp viewer showing a webpage with a map that I've created.I'm trying to add a marker in the map sending the parameters from C# to a function in the ...
4
votes
1answer
158 views

Pretty-printing WKT strings?

Is there a tool that will pretty-print well-known-text strings? One that would accept for instance MULTIPOLYGON (((40 40, 20 45, 45 30, 40 40)), ((20 35, 45 20, 30 5, 20 35))) and output something ...
2
votes
1answer
2k views

Create geometry from WKT in FME

How to create geoemtry from WKT in FME? We have a csv file in WKT format: "ID";"GEOM" "1";"LINESTRING ( 15, 20 16, 20 21, 12)" "2";"LINESTRING ( 15, 20 16, 20 21, 12)" "3";"LINESTRING ( 15, 20 16, ...
0
votes
0answers
236 views

Getting well known text from varchar in redshift.

As you know, redshift does not support geometry types. There is a column in a dataset on my redshift db that has varchar column and the format looks like: ...
0
votes
1answer
553 views

including SRID in WKBWriter in Shapely doesn't work

I want to encode coordinates of LineString in WKB with the SRID included wkbwriter = shapely.geos.WKBWriter(shapely.geos.lgeos, big_endian=False, include_srid=True) geo = wkbwriter.write_hex(...
1
vote
1answer
180 views

Visualising multiple points using QuickWKT plugin in QGIS?

Using the QuickWKT plugin in QGIS, a command of the form POINT (30 10) draws a point at the desired location. However, how can I achieve to draw multiple points in one go? I am looking for something ...
3
votes
1answer
1k views

SQL WKT draws well with geometry, but not with geography data type

I have a following piece of code DECLARE @g geometry; DECLARE @borders geography; SET @g = geometry::STGeomFromText('SOME WKT', 0); SET @borders = GEOGRAPHY::STGeomFromText(@g.MakeValid()....

1
2 3 4 5
7