Select to view content in your preferred language

Domain Coded Values or Manual Entry

594
3
Jump to solution
06-15-2022 09:58 AM
Labels (1)
JorgeKappa
Regular Contributor

Hi,

Is it possible to create a domain where the user can pick a coded value or enter a non coded value manually?

TIA

Tags (2)
0 Kudos
1 Solution

Accepted Solutions
JohannesLindner
MVP Frequent Contributor

AFAIK, it's not possible to change the manual editing workflow to "select one of the domain codes or type in your own value".

But you can insert features with "wrong" values using Python (and probably Arcade, though I haven't tested that):

with arcpy.da.InsertCursor("Table", ["Field"]) as cursor:
    cursor.insertRow([5])  # Coded Value Domain [0, 1]

JohannesLindner_1-1655359468442.png

 

 


Have a great day!
Johannes

View solution in original post

3 Replies
JohannesLindner
MVP Frequent Contributor

AFAIK, it's not possible to change the manual editing workflow to "select one of the domain codes or type in your own value".

But you can insert features with "wrong" values using Python (and probably Arcade, though I haven't tested that):

with arcpy.da.InsertCursor("Table", ["Field"]) as cursor:
    cursor.insertRow([5])  # Coded Value Domain [0, 1]

JohannesLindner_1-1655359468442.png

 

 


Have a great day!
Johannes
JorgeKappa
Regular Contributor

Thank you, Johannes. This is clever. Not something the guys in the field could do, but clever nevertheless.

0 Kudos
Kevin_MacLeod
Frequent Contributor

Greetings Jorge and @JohannesLindner  

 

I was wondering the same thing but one step further.  Ideally we would like a domain of inspector names for a field, "InspectedBy".  They could pick their name. If the name is not in the domain list, they could type in their name manually, and it would create a new domain value, so that the next time they create a record, the new value (the new inspector's name) would appear in the list to choose from the dropdown menu.  This is possible with many applications built upon SQL Server and so I was wondering if this is possible in the Esri stack. If not, Feature Enhancement.. I will be happy to create an Idea.  I can see it as a common scenario. I am guessing it's still not possible but I wanted to 'rule it out' before posting an Idea for this as a new feature.  This is a 'plumbing' issue of basic functionality I hope can be added, along with other fundamental features like this, if there is pivot from the significant Esri development focus across the stack on 3d. 

0 Kudos