Merging together Attachment Data sets

07-13-2014 03:46 PM
Occasional Contributor

... So in my attempts to navigate the ESRI, ARCGIS website to post a question... it has led me to this point... so... hopefully this would be the place to ask a simple question.... I feel lost and confused...

I have attachment data posted in ArcGIS online, but due to a misunderstanding of the MAX TABLE RETURN when publishing content, i'm limited to downloading 1000 records...... So one path i'm looking into in order to get to my data down and republish... i will need to download it in 1000 feature chunks using "Create local copy for editing". (Note that i have over 9000 points and 4 GB worth of attachment data... up in the cloud)

So now i have 8 databases, each with an attachment table, identical schema and assumed global IDs that were generated when publishing to AGO. How might one merge these attachment tables and maintain the relationship into a single MASTER dataset?

Getting the feature classes together seems is a simple enough task but i assume it can't be as easy as "loading data" into the attachment table? THere was a help doc related to restoring relationship table... but really lookin for guidance . Also i would use the Export to file geodatabase option that was recently added with the July AGO release but unfortunately, it fails due to the fact that i don' think they were expecting someone to host over 5 GB worth of attachment data

What is the easiest way to merge data together into a single attachment table and dataset?

13 Replies
Occasional Contributor

Hi Trista,

It is my understanding that Global ID's should be unique to each feature and so should REL_GlobalID.

Maybe someone else has an idea???


0 Kudos
Occasional Contributor III

The Global IDs are unique - so you should not end up with duplicates, as opposed to where you probably would with ObjectIDs. If the data was hosted on AGOL the features would have automatically been assigned Global IDs. But if you are working with data that does not have Global IDs and need them, you can add them at the Feature Dataset level.


0 Kudos
New Contributor III

Thanks to Jessica for the methodology document.  Just wanted to share my tweaked method that retains a GlobalID relationship.  This way it can go right back up to AGO or SDE.

  1. For each feature class and attachment data table add a new GUID type field

      **Note GUID fields do not seem to work well in Personal Geodatabases.  For this purpose use a File GDB

    1. New GIUD field = "Global_Holder"
    2. Populate each “Global_Holder” using the field calculator with the following:
    3. Feature Class – GlobalID
      • Field Calculator – Global_Holder = GLOBALID
    4. Attachment Table – REL_GLOBALID
      • Field Calculator – Global_Holder = REL_GLOBALID
  1. Append the feature classes so that all data is together in one Geodatabase
  2. Append the Attachment tables together
  3. Join Attachment table to appended Feature class based on “Global_Holder”
  4. Calculate Attachment table Global_Holder with Feature Class “GlobalID”
  5. Remove Join(s)
  6. In the Catalog Panel Delete the RELATIONSHIP for the attachments NOT the attachment data table for each feature class.
  7. Attachment relationship is now removed
  8. Right click in the catalog panel -> manage -> Create attachments
  9. An attachment table is now created empty. Right click table in catalog panel -> load -> load data…
  10. Load data from the merged attachment table and change the matching source field from REL_GLOBALID to Global_Holder
  11. Check to ensure attachments are now visible in ArcMap.
  12. Remove temporary fields and old attachment data tables.

Thanks, Just wanted to pay some help forward even if I am 2 years late.

New Contributor III

This was incredibly helpful!

I had four GDBs on AGOL with attachments collected in the field. I needed to get these GDBs into a enterprise GDB in-house. I was able to download from AGOL, and then load into our in-house enterprise GDB, and retain the attachments. 

One thing I did slightly differently. I created an empty schema on our enterprise database, and used the object data loader added into the editor tool bar to load the feature points (and retained the original GLOBALID in a new field) . Then I essentially followed the steps above for the attachment table.

Thank you!