Allow Default Value to be removed or changed in Hosted Feature Service Field View

16295
28
11-01-2019 10:09 AM
Status: Open
by Anonymous User
Not applicable

At this time, if you set up a Default Value for a field upon creation of a Hosted Feature Service, you have to delete and re-create the field to remove the default value.

Please allow the functionality to re-configure the Default Value of a field post hoc.

28 Comments
JoshBerna

95 kudoes, suggested in 2019 -- this must be either super hard to implement, or super low priority. Either way, I'd like to see this too.

BrianMcAuslan1

+

DanielArmstrong2

This has created issues for me as well on several City wide projects after the Field Maps systems have been launched and they have decided they want a specific default value on new features created. The only logical solution is to push the ENH ticket through and allow us to edit the default value in the AGOL data/fields configuration. I honestly do not know why it was not configured to support that in the first place. The workaround workflow that we have had to use in order to retain old values and recreate the field for everything drawing from it was sloppy at best and very time consuming.

MappyIan

The inability to edit a default value for a field is causing us issues too.  Maybe I'm searching wrong but I can't find ENH-000137389 on the Esri Support site: https://support.esri.com/en-us/search?s=Newest&cardtype=support_change_records&q=default&product=arc... 

It would be really helpful to be able to edit the default value defined on a field.  The work arounds provided are very time-consuming and prone to error as they require multiple changes in multiple different places.

L77
by

I would like to add that I posted my comments 1/2024, and now I have had to replace my default values again for 2025, since I use default values for the current year for all of our inventories.

I am hoping that by 1/2026 we may be able to just change the default value for the year column to 2026?

MikeMinami

The short answer here is:

If you want to set the default value for a field, you need to do so on the feature template used to create features. Map viewer classic supported creating and editing feature templates, and now so does Map viewer. Check out this blog post for more information.

The long answer is that the default value on a field (stored on the service) has somewhat limited utility because it gets overridden by a subtype default value and feature templates.  Even if we support changing the default value on the field, it doesn't propagate to feature templates. When you add a new feature and use a feature template, the feature template has its own default value. Now, you might think, updating the default value on the field it should also update the default value on the template. We don't do that because you may have explicitly set the default value on the template that's appropriate to the defined feature.

I hope this helps.

 

MappyIan

Thanks for that @MikeMinami, that's really helpful.  I wasn't aware Feature Templates but I've just had a play and can confirm this works as expected/required and allows me to change the default value on a field.

L77
by

I'll check out the blog post and will try it, thank you.