Updating domain/coded values in an offline setup

5299
12
Jump to solution
12-11-2014 02:22 AM
KristofferStenersen
Occasional Contributor

Hi,

An app use the AGSPopupsContainerViewController for offline feature editing (AGSGDBFeatures obtained from an offline synced AGSGDBFeatureTable). The popups editor is nice and implementation is efficient.. But this setup seem to have some limitations:

The administrator of this app sometimes needs to do domain changes to the feature services, i.e adding coded values for some of the fields.

Now, these changes does not seem to propagate out to the clients when synchonizing the offline database.

I´ve been able to work around this by setting up a temporary AGSFeatureLayer with a corresponding AGSFeature, matching the AGSGDB table and feature.. But yeah, it´s not a very pretty fix.

Any ideas on how to make a better solution to this?

0 Kudos
1 Solution

Accepted Solutions
YueWu1
by Esri Regular Contributor
Esri Regular Contributor

Hi Kristoffer,

Thanks for your detail information. One thing I want to make sure is that when the app running in online mode, can the popup container see the updated coded value (as you mentioned the 73th value)?


The reason I ask this is because if your application keep in offline mode, it will loading the old offline gdb file, which means the data scheme only have 72 values, and it can not get the updated schema. The app need to download a new offline gdb first and then can sync with new added coded value.

Please let me know if you have any other concern about this question.

View solution in original post

12 Replies
YueWu1
by Esri Regular Contributor
Esri Regular Contributor

Hi Kristoffer,

I am not really sure what do you mean by "adding coded values for some of the fields".

Do you mean adding a new coded value to an existed data schema or adding a feature with one of the existing coded value from the service?

And when edited in offline mode it can't sync back right?

Would you elaborated a little bit detail?

0 Kudos
KristofferStenersen
Occasional Contributor

Hi!

The admin adds new coded values to an existing schema. An example looking at ArcGIS rest services directory for one of the layers:

  • MyFieldName ( type: esriFieldTypeString , alias: MyAlias , editable: true , nullable: true , length: 30 , Coded Values: , , , ...72 more... )

After creating an offline gdb on the client, these 72 values propagate out to the popups editor in the client, making the end user choose which value to set for this field. But, when admin adds value 73, we´ve not been able to get this last value out to the client.

It seems that synchonization does not update the schema/available coded values for the feature tables?

Thanks! 

0 Kudos
SwenWaschk
New Contributor III

Hi,

Doesn't the admin have to update the mapservice as well. So not only the data and the datasheme?

0 Kudos
KristofferStenersen
Occasional Contributor

Hi! The admin performs a restart of the feature service in order to get the new values visible on the rest interface.

0 Kudos
SwenWaschk
New Contributor III

Does he also refresh the app?

0 Kudos
KristofferStenersen
Occasional Contributor

If you by refresh mean synchronizing the AGSGDBGeodatabase, then yes.

0 Kudos
SwenWaschk
New Contributor III

no, I think the admin needs to update the popup. Because basicly you're changing the input of the app and seeing that it doesn't work probably means that the popup also needs to be changed with a change in the domain of the geodatabase.

0 Kudos
KristofferStenersen
Occasional Contributor

We don´t maintain any popups. In the app, I´m setting up the popup using

poupInfo = [AGSPopupInfo popupInfoForGDBFeatureTable:agsFeature.table];

[[AGSPopup alloc] initWithGDBFeature:gdbFeature popupInfo:popupInfo];

Creating a default AGSPopupInfo on the information from the feature table.

0 Kudos
YueWu1
by Esri Regular Contributor
Esri Regular Contributor

Hi Kristoffer,

Thanks for your detail information. One thing I want to make sure is that when the app running in online mode, can the popup container see the updated coded value (as you mentioned the 73th value)?


The reason I ask this is because if your application keep in offline mode, it will loading the old offline gdb file, which means the data scheme only have 72 values, and it can not get the updated schema. The app need to download a new offline gdb first and then can sync with new added coded value.

Please let me know if you have any other concern about this question.