<?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: RecordSetObject: Cannot open table for Load (un-secured host) in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/recordsetobject-cannot-open-table-for-load-un/m-p/62824#M5086</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;We have a script that worked just fine until yesterday and we're getting that same error. I 'ported' it over to python 3.x which entailed changing the print statements to print() functions.&amp;nbsp;&amp;nbsp;We&amp;nbsp;originally imported urllib2 but it's no longer; after a google search, I found urllib.request has a .urlopen() method.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Bottom line, after making the changes and executing as a 3.x script, it still fails with the same error as the 2.x script does...&amp;nbsp; Sigh....&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 13 Feb 2019 23:13:56 GMT</pubDate>
    <dc:creator>JoeBorgione</dc:creator>
    <dc:date>2019-02-13T23:13:56Z</dc:date>
    <item>
      <title>RecordSetObject: Cannot open table for Load (un-secured host)</title>
      <link>https://community.esri.com/t5/python-questions/recordsetobject-cannot-open-table-for-load-un/m-p/62823#M5085</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;DIV&gt;Hi,&lt;/DIV&gt;&lt;DIV&gt;I'm experiencing an issue about FeatureSet Load method: the error is&amp;nbsp;&lt;STRONG&gt;RuntimeError: RecordSetObject:&amp;nbsp;Cannot open table for Load&lt;/STRONG&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;The service I'm requesting is&amp;nbsp;on an unsecured&amp;nbsp;host and I'm using a specific context to workaround:&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;EM&gt;requests.packages.urllib3.disable_warnings()&lt;/EM&gt;&lt;P&gt;&lt;EM&gt;os.environ['PYTHONWARNINGS']="ignore:Unverified HTTPS request"&lt;/EM&gt;&lt;/P&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;This is my simple code:&lt;/DIV&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;DIV style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&lt;SPAN style="font-size: 15px; font-family: terminal, monaco, monospace;"&gt;def createFeatureSet(serviceUrl, layerId, bbox):&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&lt;SPAN style="font-size: 15px; font-family: terminal, monaco, monospace;"&gt;&amp;nbsp; &amp;nbsp; fsURL = buildUrl(serviceUrl, layerId,bbox)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&lt;SPAN style="font-size: 15px; font-family: terminal, monaco, monospace;"&gt;&amp;nbsp; &amp;nbsp; fs = arcpy.FeatureSet()&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&lt;SPAN style="font-size: 15px; font-family: terminal, monaco, monospace;"&gt;&amp;nbsp; &amp;nbsp; result= urllib.urlopen(fsURL, context = ctx)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&lt;SPAN style="font-size: 15px; font-family: terminal, monaco, monospace;"&gt;&amp;nbsp; &amp;nbsp; fs.load(result)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&lt;SPAN style="font-size: 15px; font-family: terminal, monaco, monospace;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; return fs&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&lt;/DIV&gt;&lt;DIV style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&lt;SPAN style="font-size: 15px; font-family: terminal, monaco, monospace;"&gt;fs_item = createFeatureSet(serviceUrl, l, bbox)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&lt;SPAN style="font-size: 15px; font-family: terminal, monaco, monospace;"&gt;fs_item.save("in_memory\\outlyr.shp")&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV style="color: #222222; background-color: #ffffff; font-size: small;"&gt;&lt;SPAN style="font-size: 15px; font-family: terminal, monaco, monospace;"&gt;arcpy.MakeFeatureLayer_management("in_memory\\outlyr.shp", "outlayer")&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;Following error trace:&lt;/P&gt;&lt;DIV class="" style="color: #222222; background-color: #ffffff; font-size: medium; padding: 0px 0px 20px;"&gt;&lt;DIV class=""&gt;&lt;DIV class="" style="font-size: 12.8px; margin: 8px 0px 0px;"&gt;&lt;DIV class=""&gt;&lt;DIV dir="ltr"&gt;&lt;DIV dir="ltr"&gt;&lt;DIV dir="ltr"&gt;&lt;DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #ff0000;"&gt;Traceback (most recent call last):&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #ff0000;"&gt;&amp;nbsp; File "myscript.py", line 85, in &amp;lt;module&amp;gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #ff0000;"&gt;&amp;nbsp; &amp;nbsp; fs_item = createFeatureSet(serviceUrl, l, bbox)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #ff0000;"&gt;&amp;nbsp; File "&lt;SPAN style="background-color: #ffffff;"&gt;myscript&lt;/SPAN&gt;&lt;SPAN style="background-color: #ffffff;"&gt;.py&lt;/SPAN&gt;", line 80, in createFeatureSet&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #ff0000;"&gt;&amp;nbsp; &amp;nbsp; fs.load(result)&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #ff0000;"&gt;&amp;nbsp; File "C:\Program Files (x86)\ArcGIS\Desktop10.5\ArcPy\arcpy\arcobjects\arcobjects.py", line 175, in load&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #ff0000;"&gt;&amp;nbsp; &amp;nbsp; return convertArcObjectToPythonObject(self._arc_object.Load(*gp_fixargs(args)))&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #ff0000;"&gt;&lt;STRONG&gt;RuntimeError: RecordSetObject:&lt;SPAN style="font-size: 13px;"&gt;&amp;nbsp;Cannot open table for Load&lt;/SPAN&gt;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;/DIV&gt;&lt;DIV&gt;I tried also these snippets, but I get the same error.&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #ff0000;"&gt;&lt;STRONG style="font-size: 13px; "&gt;&lt;A href="https://community.esri.com/thread/83654"&gt;example for using token for exporting secured feature service to feature class&lt;/A&gt;&amp;nbsp;&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #ff0000;"&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;Do you have any ideas?&lt;/DIV&gt;&lt;DIV&gt;Thanks,&lt;/DIV&gt;&lt;DIV&gt;Gianni&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 06 Feb 2019 13:55:46 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/recordsetobject-cannot-open-table-for-load-un/m-p/62823#M5085</guid>
      <dc:creator>GianniContino</dc:creator>
      <dc:date>2019-02-06T13:55:46Z</dc:date>
    </item>
    <item>
      <title>Re: RecordSetObject: Cannot open table for Load (un-secured host)</title>
      <link>https://community.esri.com/t5/python-questions/recordsetobject-cannot-open-table-for-load-un/m-p/62824#M5086</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;We have a script that worked just fine until yesterday and we're getting that same error. I 'ported' it over to python 3.x which entailed changing the print statements to print() functions.&amp;nbsp;&amp;nbsp;We&amp;nbsp;originally imported urllib2 but it's no longer; after a google search, I found urllib.request has a .urlopen() method.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Bottom line, after making the changes and executing as a 3.x script, it still fails with the same error as the 2.x script does...&amp;nbsp; Sigh....&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 13 Feb 2019 23:13:56 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/recordsetobject-cannot-open-table-for-load-un/m-p/62824#M5086</guid>
      <dc:creator>JoeBorgione</dc:creator>
      <dc:date>2019-02-13T23:13:56Z</dc:date>
    </item>
  </channel>
</rss>

