Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.
SOLVED

Questions about spatial data

longhui
7 - Meteor

My data is like this   

 

POLYGON ((110.332841402 27.018266461, 110.332906738 27.018266461, 110.332906738 27.018333282, 110.332841402 27.018333282, 110.332841402 27.018266461))

 

This is spatial polygon data,QGIS Can be directly applied,but,alteryx not considered spatial data. Is there any way to process the data directly?

 

thanks!

5 REPLIES 5
longhui
7 - Meteor

sorry my  mistake

grossal
15 - Aurora
15 - Aurora

Hi @longhui,

 

you can convert your String to a spatial (Polygon) object with some tricks. I used @CharlieS workflow from this post as a starting point and adapted it to your format to make the Polygon-String a Spatial-Polygon.

 

grossal_0-1586081334037.png

Workflow attached. Let me know what you think and if it works.

 

Best

Alex

CharlieS
17 - Castor
17 - Castor

I see my work precedes me. What you have @longhui, is spatial data formatted as WKT or "Well Known Text".The good news is that this text has all the data we need to generate the spatial objects in Alteryx as mentioned above.

 

https://en.wikipedia.org/wiki/Well-known_text_representation_of_geometry

 

Another option if you're querying this WKT from a SQL database, is using STGeomFromText( and the query will convert the text and return the spatial object for you. 

 

https://docs.microsoft.com/en-us/sql/t-sql/spatial-geometry/stgeomfromtext-geometry-data-type?view=s...

 

 

longhui
7 - Meteor

Thank you, your method can solve the problem, but hope Alteryx has a more direct way to read spatial data.

longhui
7 - Meteor

Thank you for your reply.

Labels