Select to view content in your preferred language

Publish FGDB to Feature Layer: domain values disappear?

03-21-2019 03:44 AM
MVP Regular Contributor

Hi all,

My question is: why is it that domain values are not implemented to the fields in a layer in a FeatureServer when you publish Feature Classes from an FGDB containing domain values?

This is the workflow I have followed (Python files to replicate this workflow can be found in the attached zip file):

  1. I have a Python (ArcPY) script to create an FGDB - with Editor Tracking and Attachments enabled, and wit coded domain values applied to multiple fields.
  2. After creation, I have (manually) zipped the FGDB
  3. Next I use a Python script to upload the FGDB to ArcGIS Online, and once uploaded the Feature Classes from this FGDB are published to a FeatureServer /Hosted Feature Layer. This script also takes care of all kinds of adminstrative tasks, like adding a Snippet, a Description, the Terms of Use, Tags, Credits and a Thumbnail.

Everything looks fine after publication, except for the Coded Value Domains which where present in the FGDB: these are not applied to the fields in the layers in the FeatureServer... These fields just remain free fields with no domains attached. And that's a pity, isn't it?

Can anyone advise?

Pythons files used in this process (see attached zip file) - please feel free to have a look at the code; it creates just a simple FGBD for demonstration purposes:

  1. Step 1 above: together with and feature_class_fields.csv
  2. Step 3 above: together with and my_credentials.json

Of course I can add the domains afterwards, manually (using the ArcGIS Online UI) or using the ArcGIS API for Python, but I just wonder why the domain values are not implemented in the first place.

Thanks in advance,


0 Kudos
1 Reply
New Contributor II

Having the same issue;  my coded values vanish upon publishing a FGDB.    Did you figure this out?  

0 Kudos