<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: ArcGIS Python API's WKT doesn't match EWKT from PostGIS in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223384#M17271</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;How strange. I am just getting the same non-WKT I posted in my original question in both a Jupyter notebook and on a MacBook running python 3.6. Thanks for your help, but for now, we just dumped it to JSON, read that into a Python dictionary, and transmogrified it into WKT that PostGIS will accept. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I may circle back on this in Windows using the ArcGIS-supplied python just out of curiosity, but if I can't count on it working reliably in all environments (this will probably go to an Ubuntu Server or AWS Lambda for production), then I can't use it.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 14 Nov 2017 18:49:51 GMT</pubDate>
    <dc:creator>DavidAskov1</dc:creator>
    <dc:date>2017-11-14T18:49:51Z</dc:date>
    <item>
      <title>ArcGIS Python API's WKT doesn't match EWKT from PostGIS</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223378#M17265</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all - I am trying to retrieve features from an ArcGIS Server 10.31 map service using the ArcGIS Python API and insert them into PostgreSQL/PostGIS. For the geometry, both use WKT, but they don't have the same format. Here is a snippet of what I run to get the data:&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; arcgis
&lt;SPAN class="keyword token"&gt;from&lt;/SPAN&gt; arcgis&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;gis &lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; GIS
&lt;SPAN class="keyword token"&gt;from&lt;/SPAN&gt; arcgis&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;features &lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; FeatureLayer
&lt;SPAN class="keyword token"&gt;from&lt;/SPAN&gt; arcgis&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;geometry &lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; Geometry

perimetersLAYER &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; FeatureLayer&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;&lt;SPAN&gt;'&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="https://community.esri.com/external-link.jspa?url=https%3A%2F%2F" target="_blank"&gt;https://&lt;/A&gt;&lt;SPAN&gt;&amp;lt;URL&amp;gt;/arcgis/rest/services/&amp;lt;service&amp;gt;/MapServer/1'&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
perimeters_feature_set &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; perimetersLAYER&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;query&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;where&lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;"objectid = 8605"&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;

&lt;SPAN class="keyword token"&gt;for&lt;/SPAN&gt; feature &lt;SPAN class="keyword token"&gt;in&lt;/SPAN&gt; perimeters_feature_set&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;features&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="keyword token"&gt;print&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;'\n\n'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="keyword token"&gt;for&lt;/SPAN&gt; field &lt;SPAN class="keyword token"&gt;in&lt;/SPAN&gt; feature&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;fields&lt;SPAN class="punctuation token"&gt;:&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="keyword token"&gt;print&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;field &lt;SPAN class="operator token"&gt;+&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;': '&lt;/SPAN&gt; &lt;SPAN class="operator token"&gt;+&lt;/SPAN&gt; str&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;feature&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;get_value&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;field&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; 
&amp;nbsp;&amp;nbsp;&amp;nbsp; geom &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; Geometry&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;feature&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;geometry&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="keyword token"&gt;print&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;'geom.WKT: '&lt;/SPAN&gt; &lt;SPAN class="operator token"&gt;+&lt;/SPAN&gt; str&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;geom&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;WKT&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; ‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The ArcGIS Python API Geometry response looks like this:&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;SPAN style="font-family: courier new,courier,monospace;"&gt;MULTIPOLYGON (((-13645793.9305409509688616,&amp;nbsp; 4645922.6947647286579013), 
(-13645734.9949775058776140,&amp;nbsp; 4645907.8913778141140938), 
(-13645738.5948890540748835,&amp;nbsp; 4645918.5636747097596526), 
(-13645706.8243041206151247,&amp;nbsp; 4645943.8052548961713910), [SNIP]
&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;I'd like to pass this directly to a SQL insert with the &lt;A href="https://postgis.net/docs/using_postgis_dbmanagement.html#EWKB_EWKT" rel="nofollow noopener noreferrer" target="_blank"&gt;PostGIS MULTIPOLYGON&lt;/A&gt; function, which looks like this:&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;SPAN style="color: #2e2e2e; font-family: courier new,courier,monospace; font-size: 13.3333px; font-style: normal; font-variant-ligatures: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; text-align: left; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; -webkit-text-stroke-width: 0px; background-color: #ffffff; text-decoration-style: initial; text-decoration-color: initial; display: inline !important; float: none;"&gt;MULTIPOLYGON(((0 0 0,4 0 0,4 4 0,0 4 0,0 0 0),(1 1 0,2 1 0,2 2 0,1 2 0,1 1 0)),((-1 -1 0,-1 -2 0,-2 -2 0,-2 -1 0,-1 -1 0)))&lt;/SPAN&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note that the geometry formats are slightly different. In PostGIS, the x/y/z coords are &lt;SPAN style="text-decoration: underline;"&gt;&lt;EM&gt;space&lt;/EM&gt;&lt;/SPAN&gt;&lt;EM&gt; &lt;/EM&gt;delimited and each vertex is comma delimited. The Esri geometry's x/y coords are &lt;SPAN style="text-decoration: underline;"&gt;&lt;EM&gt;comma&lt;/EM&gt;&lt;/SPAN&gt; delimited, and each vertex is wrapped in parentheses and also comma delimited.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I can parse all the strings and munge the formats from one to another, but is there a way to automagically convert from one to another? It looks like Esri's WKT does not match the input PostGIS needs for its WKT functions. When I try the Geometry's WKB and JSON properties, it returns &lt;SPAN style="font-family: courier new,courier,monospace;"&gt;None&lt;/SPAN&gt;, so I'm not sure where to go with that.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Of course the geometry format is the minutia of my problem. The bigger picture issue is to find the shortest path from an ArcGIS Enterprise map service to PostGIS. If there's a better way, I'm all ears, though I'd like to keep it in python and run it on Linux. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 10:52:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223378#M17265</guid>
      <dc:creator>DavidAskov1</dc:creator>
      <dc:date>2021-12-11T10:52:13Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS Python API's WKT doesn't match EWKT from PostGIS</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223379#M17266</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Since EWKT and EWKB are more a PostGIS creation than a standard like WKT and WKB, I would use the latter if you are actually moving data between systems.&amp;nbsp; I don't have anything against EWKT or EWKB, I just don't see them as very robust from a systems interoperability perspective.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This isn't an overall Esri issue but one for the ArcGIS API for Python.&amp;nbsp; If you look at ArcPy, WKT is handled properly:&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; pg &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; arcpy&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;FromWKT&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;'MULTIPOLYGON Z(((0 0 0,4 0 0,4 4 0,0 4 0,0 0 0),(1 1 0,2 1 0,2 2 0,1 2 0,1 1 0)),((-1 -1 0,-1 -2 0,-2 -2 0,-2 -1 0,-1 -1 0)))'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; pg&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;WKT
u&lt;SPAN class="string token"&gt;'MULTIPOLYGON Z (((0 0 0, 4 0 0, 4 4 0, 0 4 0, 0 0 0), (1 1 0, 1 2 0, 2 2 0, 2 1 0, 1 1 0)), ((-1 -1 0, -2 -1 0, -2 -2 0, -1 -2 0, -1 -1 0)))'&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; ‍‍‍‍&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The WKT coming from the Python API is clearly butchered, in a couple of ways.&amp;nbsp; I haven't investigated enough to know whether this is a unique situation or a broader issue in the code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sharing with &lt;A href="https://community.esri.com/groups/arcgis-python-api?sr=search&amp;amp;searchId=a9b70294-0900-4a50-b48c-ae5a96efe771&amp;amp;searchIndex=1" target="_blank"&gt;https://community.esri.com/groups/arcgis-python-api?sr=search&amp;amp;searchId=a9b70294-0900-4a50-b48c-ae5a96efe771&amp;amp;searchIndex=1&lt;/A&gt;‌&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 10:52:16 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223379#M17266</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2021-12-11T10:52:16Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS Python API's WKT doesn't match EWKT from PostGIS</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223380#M17267</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Joshua - Thanks. I'm not too familiar with the delta between WKT &amp;amp; EWKT. For simple features, they seem to be about the same. Setting that issue aside, however, the ArcGIS Python API's WKT is quite different, so thanks for confirming I'm not crazy or doing something wrong in my code. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I appreciate the ArcPy solution, but we're hoping to avoid all that overhead for now on our little Linux server. Without ArcPy, is it safe to say that writing some code to reformat ArcGIS WKT into PostGIS WKT is our fastest approach? It's not a big job, but then I suppose we'll have to eventually do point, line, and polygon, plus the "multi" versions of each. Any other suggestions are welcome. &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Oct 2017 18:10:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223380#M17267</guid>
      <dc:creator>DavidAskov1</dc:creator>
      <dc:date>2017-10-25T18:10:56Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS Python API's WKT doesn't match EWKT from PostGIS</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223381#M17268</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What version of the API are you using?&amp;nbsp; I created a simple polygon in one of my hosted feature layers, and I am not seeing the odd WKT output.&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; arcgis
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;print&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;arcgis&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;__version__&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="number token"&gt;1.2&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;&lt;SPAN class="number token"&gt;4&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;from&lt;/SPAN&gt; arcgis&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;gis &lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; GIS
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;from&lt;/SPAN&gt; arcgis&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;features &lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; FeatureLayer
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;from&lt;/SPAN&gt; arcgis&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;geometry &lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; Geometry
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; perimetersLAYER &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; FeatureLayer&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;&lt;SPAN&gt;'&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="https://community.esri.com/external-link.jspa?url=https%3A%2F%2Ffqdn%2Farcgis%2Frest%2Fservices%2FHosted%2FSNF_LandStatus%2FFeatureServer%2F0" target="_blank"&gt;https://fqdn/arcgis/rest/services/Hosted/SNF_LandStatus/FeatureServer/0&lt;/A&gt;&lt;SPAN&gt;'&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; perimeters_feature_set &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; perimetersLAYER&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;query&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;where&lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;'objectid=4'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; feature &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; next&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;f &lt;SPAN class="keyword token"&gt;for&lt;/SPAN&gt; f &lt;SPAN class="keyword token"&gt;in&lt;/SPAN&gt; perimeters_feature_set&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; geom &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; Geometry&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;feature&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;geometry&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;print&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;geom&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;WKT&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
MULTIPOLYGON &lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;&lt;SPAN class="number token"&gt;463774.0959999999&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;5387170.5483999997&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;474346.17119999975&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;5213428.8544999994&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;751430.00449999981&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;5214531.3746000007&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;733288.65990000032&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;5391894.7993000001&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;513147.3208999997&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;5387069.2414999995&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;,&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;463774.0959999999&lt;/SPAN&gt; &lt;SPAN class="number token"&gt;5387170.5483999997&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 10:52:18 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223381#M17268</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2021-12-11T10:52:18Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS Python API's WKT doesn't match EWKT from PostGIS</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223382#M17269</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am also running 1.2.4. I tried it on a Jupyter notebook and a regular install of Python on a Macbook - same result.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The ArcGIS Server is 10.31, could that be the isssue? &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 26 Oct 2017 21:56:49 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223382#M17269</guid>
      <dc:creator>DavidAskov1</dc:creator>
      <dc:date>2017-10-26T21:56:49Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS Python API's WKT doesn't match EWKT from PostGIS</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223383#M17270</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Unless your organization has a public-facing service, or you can find a public-facing service that demonstrates the issue, I don't have any more specific suggestions.&amp;nbsp; I believe my organization still has some 10.3.1 services running, so I will test on one of them when I can find the time.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;UPDATE&lt;/STRONG&gt;:&amp;nbsp; I found a public-facing 10.3.1 server my organization has with some feature services.&amp;nbsp; The following feature service outputs normal WKT using ArcGIS API for Python.&lt;/P&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;&lt;CODE&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;from&lt;/SPAN&gt; arcgis&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;gis &lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; GIS
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;from&lt;/SPAN&gt; arcgis&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;features &lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; FeatureLayer
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;from&lt;/SPAN&gt; arcgis&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;geometry &lt;SPAN class="keyword token"&gt;import&lt;/SPAN&gt; Geometry
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; url &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; &lt;SPAN class="string token"&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="https://community.esri.com/external-link.jspa?url=https%3A%2F%2Fapps.fs.usda.gov%2Farcx%2Frest%2Fservices%2FEDW_FEATURE%2FEDW_Wilderness_01%2FFeatureServer%2F0" target="_blank"&gt;https://apps.fs.usda.gov/arcx/rest/services/EDW_FEATURE/EDW_Wilderness_01/FeatureServer/0&lt;/A&gt;&lt;SPAN&gt;"&lt;/SPAN&gt;&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; perimetersLAYER &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; FeatureLayer&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;url&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; perimeters_feature_set &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; perimetersLAYER&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;query&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;where&lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt;&lt;SPAN class="string token"&gt;'wid=708'&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; feature &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; next&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;f &lt;SPAN class="keyword token"&gt;for&lt;/SPAN&gt; f &lt;SPAN class="keyword token"&gt;in&lt;/SPAN&gt; perimeters_feature_set&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; geom &lt;SPAN class="operator token"&gt;=&lt;/SPAN&gt; Geometry&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;feature&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;geometry&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; &lt;SPAN class="keyword token"&gt;print&lt;/SPAN&gt;&lt;SPAN class="punctuation token"&gt;(&lt;/SPAN&gt;geom&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;WKT&lt;SPAN class="punctuation token"&gt;)&lt;/SPAN&gt;
&lt;SPAN class="operator token"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN class="operator token"&gt;&amp;gt;&lt;/SPAN&gt; geom&lt;SPAN class="punctuation token"&gt;.&lt;/SPAN&gt;WKT
&lt;SPAN class="string token"&gt;'MULTIPOLYGON (((-80.309682070000008 37.883744509999985, -80.309682090000024 37.883581180000022, ..., -80.309682070000008 37.883744509999985)))'&lt;/SPAN&gt;&lt;SPAN class="line-numbers-rows"&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;SPAN&gt;‍&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 11 Dec 2021 10:52:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223383#M17270</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2021-12-11T10:52:21Z</dc:date>
    </item>
    <item>
      <title>Re: ArcGIS Python API's WKT doesn't match EWKT from PostGIS</title>
      <link>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223384#M17271</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;How strange. I am just getting the same non-WKT I posted in my original question in both a Jupyter notebook and on a MacBook running python 3.6. Thanks for your help, but for now, we just dumped it to JSON, read that into a Python dictionary, and transmogrified it into WKT that PostGIS will accept. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I may circle back on this in Windows using the ArcGIS-supplied python just out of curiosity, but if I can't count on it working reliably in all environments (this will probably go to an Ubuntu Server or AWS Lambda for production), then I can't use it.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Nov 2017 18:49:51 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/arcgis-python-api-s-wkt-doesn-t-match-ewkt-from/m-p/223384#M17271</guid>
      <dc:creator>DavidAskov1</dc:creator>
      <dc:date>2017-11-14T18:49:51Z</dc:date>
    </item>
  </channel>
</rss>

