<?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 RuntimeError: Object: Error in executing tool (in XYTableToPoint) in Python Questions</title>
    <link>https://community.esri.com/t5/python-questions/runtimeerror-object-error-in-executing-tool-in/m-p/1039180#M60516</link>
    <description>&lt;P&gt;This is the code I write and it gives me following error.&amp;nbsp;&lt;/P&gt;&lt;P&gt;# reading the csv file containing wildfire data&lt;BR /&gt;fires_dataset=pd.read_csv(r'D:/UCALGARY/urbanGIS/lab4/lab4data/fires_data.csv',encoding='mac_roman')&lt;/P&gt;&lt;P&gt;# specify the location you want the store your point features after running the XY to Point tool.&lt;BR /&gt;fire_data_output = r'D:/UCALGARY/urban GIS/lab4/lab4ugis/lab4ugis.aprx'&lt;/P&gt;&lt;P&gt;fires_data = arcpy.management.XYTableToPoint(fires_dataset,fire_data_output, 'fire_location_longitude', 'fire_location_latitude')&lt;/P&gt;&lt;P&gt;Error&lt;/P&gt;&lt;PRE&gt;&lt;SPAN class="ansi-red-fg"&gt;RuntimeError&lt;/SPAN&gt;                              Traceback (most recent call last)
In  &lt;SPAN class="ansi-blue-fg"&gt;[7]&lt;/SPAN&gt;:
Line &lt;SPAN class="ansi-blue-fg"&gt;9&lt;/SPAN&gt;:     fires_data = arcpy.management.XYTableToPoint(fires_dataset,fire_data_output, &lt;SPAN class="ansi-yellow-fg"&gt;'&lt;/SPAN&gt;&lt;SPAN class="ansi-yellow-fg"&gt;fire_location_longitude&lt;/SPAN&gt;&lt;SPAN class="ansi-yellow-fg"&gt;'&lt;/SPAN&gt;, &lt;SPAN class="ansi-yellow-fg"&gt;'&lt;/SPAN&gt;&lt;SPAN class="ansi-yellow-fg"&gt;fire_location_latitude&lt;/SPAN&gt;&lt;SPAN class="ansi-yellow-fg"&gt;'&lt;/SPAN&gt;)

File &lt;SPAN class="ansi-blue-fg"&gt;c:\program files\arcgis\pro\Resources\arcpy\arcpy\management.py&lt;/SPAN&gt;, in &lt;SPAN class="ansi-green-fg"&gt;XYTableToPoint&lt;/SPAN&gt;:
Line &lt;SPAN class="ansi-blue-fg"&gt;4151&lt;/SPAN&gt;:  &lt;SPAN class="ansi-blue-fg"&gt;raise&lt;/SPAN&gt; e

File &lt;SPAN class="ansi-blue-fg"&gt;c:\program files\arcgis\pro\Resources\arcpy\arcpy\management.py&lt;/SPAN&gt;, in &lt;SPAN class="ansi-green-fg"&gt;XYTableToPoint&lt;/SPAN&gt;:
Line &lt;SPAN class="ansi-blue-fg"&gt;4148&lt;/SPAN&gt;:  retval = convertArcObjectToPythonObject(gp.XYTableToPoint_management(*gp_fixargs((in_table, out_feature_class, x_field, y_field, z_field, coordinate_system), &lt;SPAN class="ansi-blue-fg"&gt;True&lt;/SPAN&gt;)))

File &lt;SPAN class="ansi-blue-fg"&gt;c:\program files\arcgis\pro\Resources\arcpy\arcpy\geoprocessing\_base.py&lt;/SPAN&gt;, in &lt;SPAN class="ansi-green-fg"&gt;&amp;lt;lambda&amp;gt;&lt;/SPAN&gt;:
Line &lt;SPAN class="ansi-blue-fg"&gt;511&lt;/SPAN&gt;:   &lt;SPAN class="ansi-blue-fg"&gt;return&lt;/SPAN&gt; &lt;SPAN class="ansi-blue-fg"&gt;lambda&lt;/SPAN&gt; *args: val(*gp_fixargs(args, &lt;SPAN class="ansi-blue-fg"&gt;True&lt;/SPAN&gt;))

&lt;SPAN class="ansi-red-fg"&gt;RuntimeError&lt;/SPAN&gt;: Object: Error in executing tool&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 22 Mar 2021 04:21:21 GMT</pubDate>
    <dc:creator>NabilaChaudhry</dc:creator>
    <dc:date>2021-03-22T04:21:21Z</dc:date>
    <item>
      <title>RuntimeError: Object: Error in executing tool (in XYTableToPoint)</title>
      <link>https://community.esri.com/t5/python-questions/runtimeerror-object-error-in-executing-tool-in/m-p/1039180#M60516</link>
      <description>&lt;P&gt;This is the code I write and it gives me following error.&amp;nbsp;&lt;/P&gt;&lt;P&gt;# reading the csv file containing wildfire data&lt;BR /&gt;fires_dataset=pd.read_csv(r'D:/UCALGARY/urbanGIS/lab4/lab4data/fires_data.csv',encoding='mac_roman')&lt;/P&gt;&lt;P&gt;# specify the location you want the store your point features after running the XY to Point tool.&lt;BR /&gt;fire_data_output = r'D:/UCALGARY/urban GIS/lab4/lab4ugis/lab4ugis.aprx'&lt;/P&gt;&lt;P&gt;fires_data = arcpy.management.XYTableToPoint(fires_dataset,fire_data_output, 'fire_location_longitude', 'fire_location_latitude')&lt;/P&gt;&lt;P&gt;Error&lt;/P&gt;&lt;PRE&gt;&lt;SPAN class="ansi-red-fg"&gt;RuntimeError&lt;/SPAN&gt;                              Traceback (most recent call last)
In  &lt;SPAN class="ansi-blue-fg"&gt;[7]&lt;/SPAN&gt;:
Line &lt;SPAN class="ansi-blue-fg"&gt;9&lt;/SPAN&gt;:     fires_data = arcpy.management.XYTableToPoint(fires_dataset,fire_data_output, &lt;SPAN class="ansi-yellow-fg"&gt;'&lt;/SPAN&gt;&lt;SPAN class="ansi-yellow-fg"&gt;fire_location_longitude&lt;/SPAN&gt;&lt;SPAN class="ansi-yellow-fg"&gt;'&lt;/SPAN&gt;, &lt;SPAN class="ansi-yellow-fg"&gt;'&lt;/SPAN&gt;&lt;SPAN class="ansi-yellow-fg"&gt;fire_location_latitude&lt;/SPAN&gt;&lt;SPAN class="ansi-yellow-fg"&gt;'&lt;/SPAN&gt;)

File &lt;SPAN class="ansi-blue-fg"&gt;c:\program files\arcgis\pro\Resources\arcpy\arcpy\management.py&lt;/SPAN&gt;, in &lt;SPAN class="ansi-green-fg"&gt;XYTableToPoint&lt;/SPAN&gt;:
Line &lt;SPAN class="ansi-blue-fg"&gt;4151&lt;/SPAN&gt;:  &lt;SPAN class="ansi-blue-fg"&gt;raise&lt;/SPAN&gt; e

File &lt;SPAN class="ansi-blue-fg"&gt;c:\program files\arcgis\pro\Resources\arcpy\arcpy\management.py&lt;/SPAN&gt;, in &lt;SPAN class="ansi-green-fg"&gt;XYTableToPoint&lt;/SPAN&gt;:
Line &lt;SPAN class="ansi-blue-fg"&gt;4148&lt;/SPAN&gt;:  retval = convertArcObjectToPythonObject(gp.XYTableToPoint_management(*gp_fixargs((in_table, out_feature_class, x_field, y_field, z_field, coordinate_system), &lt;SPAN class="ansi-blue-fg"&gt;True&lt;/SPAN&gt;)))

File &lt;SPAN class="ansi-blue-fg"&gt;c:\program files\arcgis\pro\Resources\arcpy\arcpy\geoprocessing\_base.py&lt;/SPAN&gt;, in &lt;SPAN class="ansi-green-fg"&gt;&amp;lt;lambda&amp;gt;&lt;/SPAN&gt;:
Line &lt;SPAN class="ansi-blue-fg"&gt;511&lt;/SPAN&gt;:   &lt;SPAN class="ansi-blue-fg"&gt;return&lt;/SPAN&gt; &lt;SPAN class="ansi-blue-fg"&gt;lambda&lt;/SPAN&gt; *args: val(*gp_fixargs(args, &lt;SPAN class="ansi-blue-fg"&gt;True&lt;/SPAN&gt;))

&lt;SPAN class="ansi-red-fg"&gt;RuntimeError&lt;/SPAN&gt;: Object: Error in executing tool&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 22 Mar 2021 04:21:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/runtimeerror-object-error-in-executing-tool-in/m-p/1039180#M60516</guid>
      <dc:creator>NabilaChaudhry</dc:creator>
      <dc:date>2021-03-22T04:21:21Z</dc:date>
    </item>
    <item>
      <title>Re: RuntimeError: Object: Error in executing tool (in XYTableToPoint)</title>
      <link>https://community.esri.com/t5/python-questions/runtimeerror-object-error-in-executing-tool-in/m-p/1039184#M60517</link>
      <description>&lt;P&gt;You need to pass a feature class not an ArcGIS Pro aprx file as the output.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 22 Mar 2021 05:29:21 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/runtimeerror-object-error-in-executing-tool-in/m-p/1039184#M60517</guid>
      <dc:creator>Luke_Pinner</dc:creator>
      <dc:date>2021-03-22T05:29:21Z</dc:date>
    </item>
    <item>
      <title>Re: RuntimeError: Object: Error in executing tool (in XYTableToPoint)</title>
      <link>https://community.esri.com/t5/python-questions/runtimeerror-object-error-in-executing-tool-in/m-p/1039185#M60518</link>
      <description>&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;The second parameter should be a new feature class name (something like r'D:\temp\abc.gdb\fc') and not an aprx.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Have fun&lt;/P&gt;&lt;P&gt;Mody&lt;/P&gt;</description>
      <pubDate>Mon, 22 Mar 2021 05:30:08 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/runtimeerror-object-error-in-executing-tool-in/m-p/1039185#M60518</guid>
      <dc:creator>mody_buchbinder</dc:creator>
      <dc:date>2021-03-22T05:30:08Z</dc:date>
    </item>
    <item>
      <title>Re: RuntimeError: Object: Error in executing tool (in XYTableToPoint)</title>
      <link>https://community.esri.com/t5/python-questions/runtimeerror-object-error-in-executing-tool-in/m-p/1039204#M60519</link>
      <description>&lt;P&gt;Hi, I did try what you said but it is giving me the same error.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 22 Mar 2021 09:11:03 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/runtimeerror-object-error-in-executing-tool-in/m-p/1039204#M60519</guid>
      <dc:creator>NabilaChaudhry</dc:creator>
      <dc:date>2021-03-22T09:11:03Z</dc:date>
    </item>
    <item>
      <title>Re: RuntimeError: Object: Error in executing tool (in XYTableToPoint)</title>
      <link>https://community.esri.com/t5/python-questions/runtimeerror-object-error-in-executing-tool-in/m-p/1039231#M60520</link>
      <description>&lt;P&gt;I don't think a pandas dataframe is an allowed input.&amp;nbsp; I would just reference the path to the csv in&amp;nbsp;&lt;SPAN&gt;arcpy.management.XYTableToPoint&lt;/SPAN&gt; and do away with any pandas.&lt;/P&gt;</description>
      <pubDate>Mon, 22 Mar 2021 11:11:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/runtimeerror-object-error-in-executing-tool-in/m-p/1039231#M60520</guid>
      <dc:creator>DavidPike</dc:creator>
      <dc:date>2021-03-22T11:11:45Z</dc:date>
    </item>
    <item>
      <title>Re: RuntimeError: Object: Error in executing tool (in XYTableToPoint)</title>
      <link>https://community.esri.com/t5/python-questions/runtimeerror-object-error-in-executing-tool-in/m-p/1675158#M75025</link>
      <description>&lt;P&gt;For anyone else who has run into this error (and this page) and wants to go between a pandas dataframe and feature class, I was able to use&amp;nbsp;arcpy.management.XYTableToPoint for this. The trick is you first need to import the GeoAccessor with the following code (I don't know if the GeoSeriesAccessor is strictly necessary, but I've usually seen them together):&lt;/P&gt;&lt;LI-CODE lang="python"&gt;from arcgis.features import GeoAccessor, GeoSeriesAccessor&lt;/LI-CODE&gt;&lt;P&gt;If you need to do some spatial operations first, you can use&amp;nbsp;pd.DataFrame.spatial.from_xy (&lt;A href="https://developers.arcgis.com/python/latest/guide/part1-introduction-to-sedf/" target="_self"&gt;Esri example here&lt;/A&gt;) and then df.spatial.to_featureclass (with your own dataframe variable as the first part) to move the final dataframe to a database.&lt;/P&gt;&lt;P&gt;I agree with this response that using&amp;nbsp;arcpy.management.XYTableToPoint and pointing to the csv is better in the original situation, but perhaps this information will be useful to others who run into the same error.&lt;/P&gt;</description>
      <pubDate>Mon, 29 Dec 2025 17:58:04 GMT</pubDate>
      <guid>https://community.esri.com/t5/python-questions/runtimeerror-object-error-in-executing-tool-in/m-p/1675158#M75025</guid>
      <dc:creator>LReis</dc:creator>
      <dc:date>2025-12-29T17:58:04Z</dc:date>
    </item>
  </channel>
</rss>

