<?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 Sychronising data between Hosted Feature Services and File Geodatabases? in ArcGIS Enterprise Questions</title>
    <link>https://community.esri.com/t5/arcgis-enterprise-questions/sychronising-data-between-hosted-feature-services/m-p/1237573#M34716</link>
    <description>&lt;P&gt;We're looking for ways to synchronise Hosted Feature Services with our main file server geodatabases. One approach may be to do away with hosted and use lots of Enterprise GDBs. However, I'm wandering if anyone has come up with a novel way to synchronise the Hosted data with existing File GDBs within our projects.&amp;nbsp;&lt;/P&gt;&lt;P&gt;The aim of the game is one-truth data management, so we're reluctant to operate with a Hosted environment due to other geodata requirements across the business.&lt;/P&gt;</description>
    <pubDate>Sun, 04 Dec 2022 10:57:36 GMT</pubDate>
    <dc:creator>David_Brooks</dc:creator>
    <dc:date>2022-12-04T10:57:36Z</dc:date>
    <item>
      <title>Sychronising data between Hosted Feature Services and File Geodatabases?</title>
      <link>https://community.esri.com/t5/arcgis-enterprise-questions/sychronising-data-between-hosted-feature-services/m-p/1237573#M34716</link>
      <description>&lt;P&gt;We're looking for ways to synchronise Hosted Feature Services with our main file server geodatabases. One approach may be to do away with hosted and use lots of Enterprise GDBs. However, I'm wandering if anyone has come up with a novel way to synchronise the Hosted data with existing File GDBs within our projects.&amp;nbsp;&lt;/P&gt;&lt;P&gt;The aim of the game is one-truth data management, so we're reluctant to operate with a Hosted environment due to other geodata requirements across the business.&lt;/P&gt;</description>
      <pubDate>Sun, 04 Dec 2022 10:57:36 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-enterprise-questions/sychronising-data-between-hosted-feature-services/m-p/1237573#M34716</guid>
      <dc:creator>David_Brooks</dc:creator>
      <dc:date>2022-12-04T10:57:36Z</dc:date>
    </item>
    <item>
      <title>Re: Sychronising data between Hosted Feature Services and File Geodatabases?</title>
      <link>https://community.esri.com/t5/arcgis-enterprise-questions/sychronising-data-between-hosted-feature-services/m-p/1237588#M34717</link>
      <description>&lt;P&gt;We get away with all but 2 of our services being hosted copies of authoritative data elsewhere, and we never have to really think about it. The sync process relies heavily on the ArcGIS Python API. Here's how we do it:&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;Layers&lt;BR /&gt;&lt;OL&gt;&lt;LI&gt;Source Data&lt;OL&gt;&lt;LI&gt;Can be file-based, some service, a DB, etc&lt;/LI&gt;&lt;LI&gt;Has editor tracking enabled&lt;OL&gt;&lt;LI&gt;Can work without, but is much easier with it&lt;/LI&gt;&lt;/OL&gt;&lt;/LI&gt;&lt;LI&gt;Has globlaIDs&lt;/LI&gt;&lt;/OL&gt;&lt;/LI&gt;&lt;LI&gt;Destination layer&lt;OL&gt;&lt;LI&gt;Hosted in Portal / AGOL&lt;/LI&gt;&lt;LI&gt;Has a "sourceGUID" field&lt;/LI&gt;&lt;/OL&gt;&lt;/LI&gt;&lt;LI&gt;Auxiliary layer&lt;OL&gt;&lt;LI&gt;Table names&lt;/LI&gt;&lt;LI&gt;"last updated" timestamps&lt;/LI&gt;&lt;/OL&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;/LI&gt;&lt;LI&gt;Scripts&lt;OL&gt;&lt;LI&gt;Timestamp based&lt;OL&gt;&lt;LI&gt;For a given table, pulls the "last updated" timestamp from auxiliary layer&lt;/LI&gt;&lt;LI&gt;Queries source data for features edited since that timestamp&lt;/LI&gt;&lt;LI&gt;Queries destination layer for features whose "sourceGUID" field matches any globalID from the source query.&lt;/LI&gt;&lt;LI&gt;Merges destination globalid / objectid with source attributes&lt;/LI&gt;&lt;LI&gt;Pushes source attributes back to destination layer, editing features in place&lt;/LI&gt;&lt;/OL&gt;&lt;/LI&gt;&lt;LI&gt;Comparison based (when editor tracking is not on source layer)&lt;OL&gt;&lt;LI&gt;Query entire source layer to dataframe, set globalid as index&lt;/LI&gt;&lt;LI&gt;Query entire destination layer to dataframe, set sourceGUID as index&lt;/LI&gt;&lt;LI&gt;Use pandas library &lt;STRONG&gt;compare&lt;/STRONG&gt; function&lt;OL&gt;&lt;LI&gt;Identifies rows with attribute edits&lt;/LI&gt;&lt;/OL&gt;&lt;/LI&gt;&lt;LI&gt;Compare indices&lt;OL&gt;&lt;LI&gt;Identifies rows in source not in destination (adds)&lt;/LI&gt;&lt;LI&gt;Identifies rows in destination not in source (deletes)&lt;/LI&gt;&lt;/OL&gt;&lt;/LI&gt;&lt;LI&gt;Submit adds, updates, and deletes to destination layer&lt;/LI&gt;&lt;/OL&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;It sounds like a lot, but at the end of the day, you only have to edit features that actually &lt;EM&gt;were &lt;/EM&gt;edited in the source. We keep a number of layers with 100k + features in them up to date with their sources nightly, and the process takes less than a minute per layer.&lt;/P&gt;&lt;P&gt;I recently presented on this topic at a regional GIS conference. You're welcome to look at the notes here: &lt;A href="https://github.com/jdcarls2/ilgisa-2022/tree/main/hosted-copy" target="_blank"&gt;https://github.com/jdcarls2/ilgisa-2022/tree/main/hosted-copy&lt;/A&gt;&lt;/P&gt;&lt;P&gt;It can be complex to set up, but the end result is totally worth it. You could take it a step further and use the compare function to identify not just rows with edits, but columns as well, further paring down the data exchanged during the sync process.&lt;/P&gt;</description>
      <pubDate>Sun, 04 Dec 2022 14:17:17 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-enterprise-questions/sychronising-data-between-hosted-feature-services/m-p/1237588#M34717</guid>
      <dc:creator>jcarlson</dc:creator>
      <dc:date>2022-12-04T14:17:17Z</dc:date>
    </item>
    <item>
      <title>Re: Sychronising data between Hosted Feature Services and File Geodatabases?</title>
      <link>https://community.esri.com/t5/arcgis-enterprise-questions/sychronising-data-between-hosted-feature-services/m-p/1237650#M34720</link>
      <description>&lt;P&gt;have a look at this:&lt;/P&gt;&lt;P&gt;&lt;A href="https://www.esri.com/en-us/arcgis-marketplace/listing/products/8b0aa70f82574f7298537ab966ff45b8" target="_blank"&gt;https://www.esri.com/en-us/arcgis-marketplace/listing/products/8b0aa70f82574f7298537ab966ff45b8&lt;/A&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sun, 04 Dec 2022 23:33:52 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-enterprise-questions/sychronising-data-between-hosted-feature-services/m-p/1237650#M34720</guid>
      <dc:creator>Scott_Tansley</dc:creator>
      <dc:date>2022-12-04T23:33:52Z</dc:date>
    </item>
    <item>
      <title>Re: Sychronising data between Hosted Feature Services and File Geodatabases?</title>
      <link>https://community.esri.com/t5/arcgis-enterprise-questions/sychronising-data-between-hosted-feature-services/m-p/1238152#M34738</link>
      <description>&lt;P&gt;&lt;a href="https://community.esri.com/t5/user/viewprofilepage/user-id/363906"&gt;@jcarlson&lt;/a&gt;&amp;nbsp;really nice approach that. As you say, complex to set up, but ultimately a very elegant solution. im going to weigh up the options (to EGDB or not to EGDB) before delving into this one&lt;/P&gt;</description>
      <pubDate>Tue, 06 Dec 2022 09:16:33 GMT</pubDate>
      <guid>https://community.esri.com/t5/arcgis-enterprise-questions/sychronising-data-between-hosted-feature-services/m-p/1238152#M34738</guid>
      <dc:creator>David_Brooks</dc:creator>
      <dc:date>2022-12-06T09:16:33Z</dc:date>
    </item>
  </channel>
</rss>

