<?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: How to append data to a feature service with a related table? in ArcGIS Online Questions</title>
    <link>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/709752#M35171</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I posted &lt;A _jive_internal="true" href="https://community.esri.com/thread/251478-how-to-append-guid-data-from-pro-to-arc-online"&gt;another question&lt;/A&gt; to the community to see if anyone else has seen the issue. I did not reach out to support directly. Admittedly I never watched your full video, but I think what I had been doing was similar (copy the foreign key and primary keys to another GUID and then match them back up after the append).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I wasn't ever able to get the GUID type to work, but I was able to copy the primary and foreign keys to string and match them up with a basic script I had written before I knew about your tutorial:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;import arcpy&lt;BR /&gt;import os&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;class CustomCancelException(Exception):&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;pass&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;def my_function(post_layer, sign_layer):&lt;BR /&gt; edit_started = False&lt;BR /&gt; &lt;BR /&gt; try:&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;with arcpy.da.SearchCursor(post_layer, ["GLOBALID", "preserve_guid"]) as scur:&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;key_map = {}&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;for srow in scur:&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;key_map[srow[1]] = srow[0]&lt;BR /&gt; &lt;BR /&gt;with arcpy.da.UpdateCursor(sign_layer, ["parentfk", "preserve_guid"]) as ucur:&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;for urow in ucur:&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;new_fk = key_map.get(urow[1], None)&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;urow[0] = new_fk&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;ucur.updateRow(urow)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;except CustomCancelException as err:&lt;BR /&gt; arcpy.AddError(err)&lt;BR /&gt; finally:&lt;BR /&gt;&lt;BR /&gt;if __name__ == '__main__': &lt;BR /&gt; post_layer = arcpy.GetParameter(0)&lt;BR /&gt; sign_layer = arcpy.GetParameter(1)&lt;BR /&gt; &lt;BR /&gt; my_function(post_layer, sign_layer)&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;The quotations aren't preserving indentation, but that's the general idea. I never tried copying from a string into a GUID because I thought that wouldn't work and I already had this script.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 15 Apr 2020 12:41:13 GMT</pubDate>
    <dc:creator>WillHouston</dc:creator>
    <dc:date>2020-04-15T12:41:13Z</dc:date>
    <item>
      <title>How to append data to a feature service with a related table?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/709748#M35167</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'm trying to append data to a feature service with a related table online, but I'm having trouble getting the appended data to relate to the related table.&amp;nbsp; I append the new data to the fs, then append the related records to the related table.&amp;nbsp; Any new data added (from survey123) appears as it should with its related records.&amp;nbsp; Is there a way to append new data with related records to an existing feature service and its related table?&amp;nbsp; I attached an image of the fs data if that helps.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 04 Dec 2019 14:46:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/709748#M35167</guid>
      <dc:creator>ChelseaTabor1</dc:creator>
      <dc:date>2019-12-04T14:46:33Z</dc:date>
    </item>
    <item>
      <title>Re: How to append data to a feature service with a related table?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/709749#M35168</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi &lt;A href="https://community.esri.com/migrated-users/338844"&gt;Chelsea Tabor&lt;/A&gt;‌,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is a common scenario because of the uniqueness of GlobalIDs. I recorded this video which goes through a workflow of how to address the issue, keeping parent features connected to their related records when appending:&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://youtu.be/S5V6MIrAKCk" title="https://youtu.be/S5V6MIrAKCk"&gt;How To: Preserve GlobalID/GUID Relationships when Appending Records - YouTube&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope it helps,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Peter&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 05 Feb 2020 19:05:42 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/709749#M35168</guid>
      <dc:creator>Anonymous User</dc:creator>
      <dc:date>2020-02-05T19:05:42Z</dc:date>
    </item>
    <item>
      <title>Re: How to append data to a feature service with a related table?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/709750#M35169</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;This is not working from a file geodatabase to an Arc Online feature layer using the Append tool:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Failed on input OID 3922, could not write value '{028C6C51-9C71-4D14-8E4C-0FA1B5B49A6F}' to output field match_fks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Apr 2020 20:30:02 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/709750#M35169</guid>
      <dc:creator>WillHouston</dc:creator>
      <dc:date>2020-04-14T20:30:02Z</dc:date>
    </item>
    <item>
      <title>Re: How to append data to a feature service with a related table?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/709751#M35170</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Will,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm revisiting this workflow tomorrow and will consider your scenario and error message. I'll post here if I can figure out what the issue might be. In the meantime have you reached out to Esri Support to take a look?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="link-titled" href="https://support.esri.com/en/contact-tech-support" title="https://support.esri.com/en/contact-tech-support"&gt;Esri Support Contact Support&lt;/A&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;-Peter&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Apr 2020 23:13:17 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/709751#M35170</guid>
      <dc:creator>Anonymous User</dc:creator>
      <dc:date>2020-04-14T23:13:17Z</dc:date>
    </item>
    <item>
      <title>Re: How to append data to a feature service with a related table?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/709752#M35171</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I posted &lt;A _jive_internal="true" href="https://community.esri.com/thread/251478-how-to-append-guid-data-from-pro-to-arc-online"&gt;another question&lt;/A&gt; to the community to see if anyone else has seen the issue. I did not reach out to support directly. Admittedly I never watched your full video, but I think what I had been doing was similar (copy the foreign key and primary keys to another GUID and then match them back up after the append).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I wasn't ever able to get the GUID type to work, but I was able to copy the primary and foreign keys to string and match them up with a basic script I had written before I knew about your tutorial:&lt;/P&gt;&lt;BLOCKQUOTE class="jive_macro_quote jive-quote jive_text_macro"&gt;&lt;P&gt;import arcpy&lt;BR /&gt;import os&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;class CustomCancelException(Exception):&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;pass&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;def my_function(post_layer, sign_layer):&lt;BR /&gt; edit_started = False&lt;BR /&gt; &lt;BR /&gt; try:&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;with arcpy.da.SearchCursor(post_layer, ["GLOBALID", "preserve_guid"]) as scur:&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;key_map = {}&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;for srow in scur:&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;key_map[srow[1]] = srow[0]&lt;BR /&gt; &lt;BR /&gt;with arcpy.da.UpdateCursor(sign_layer, ["parentfk", "preserve_guid"]) as ucur:&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;for urow in ucur:&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;new_fk = key_map.get(urow[1], None)&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;urow[0] = new_fk&lt;BR /&gt; &amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;ucur.updateRow(urow)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;except CustomCancelException as err:&lt;BR /&gt; arcpy.AddError(err)&lt;BR /&gt; finally:&lt;BR /&gt;&lt;BR /&gt;if __name__ == '__main__': &lt;BR /&gt; post_layer = arcpy.GetParameter(0)&lt;BR /&gt; sign_layer = arcpy.GetParameter(1)&lt;BR /&gt; &lt;BR /&gt; my_function(post_layer, sign_layer)&lt;/P&gt;&lt;/BLOCKQUOTE&gt;&lt;P&gt;The quotations aren't preserving indentation, but that's the general idea. I never tried copying from a string into a GUID because I thought that wouldn't work and I already had this script.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Apr 2020 12:41:13 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/709752#M35171</guid>
      <dc:creator>WillHouston</dc:creator>
      <dc:date>2020-04-15T12:41:13Z</dc:date>
    </item>
    <item>
      <title>Re: How to append data to a feature service with a related table?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/709753#M35172</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Will, thanks for the reply and posting your solution here - I did look into this more and I'm not sure why copying to GUID was failing. But I'm sure the above script will assist someone else and is surely quicker than the manual process in my video.&amp;nbsp;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 18 Apr 2020 19:53:27 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/709753#M35172</guid>
      <dc:creator>Anonymous User</dc:creator>
      <dc:date>2020-04-18T19:53:27Z</dc:date>
    </item>
    <item>
      <title>Re: How to append data to a feature service with a related table?</title>
      <link>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/1063686#M40351</link>
      <description>&lt;P&gt;@Anonymous User&amp;nbsp;thanks for the video this helped a bit.&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/263137"&gt;@WillHouston&lt;/a&gt;&amp;nbsp; thanks for the code, I can get everything to work except the actual editing of the table. really frustrating maybe I will modify to do select and calculate field.&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 01 Jun 2021 16:21:26 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-online-questions/how-to-append-data-to-a-feature-service-with-a/m-p/1063686#M40351</guid>
      <dc:creator>MichaelWallace3</dc:creator>
      <dc:date>2021-06-01T16:21:26Z</dc:date>
    </item>
  </channel>
</rss>

