Trying to use Coded Value Domains with Allow Null Values = No in a File GDB, ArcGIS 10.2. Through an GIS.SE question that I can't seem to find again, I found this through ArcGIS help:
"Note:
The geodatabase model is such that it will insert an empty value (numeric = 0, text = "") instead of a database NULL if, and only if, the field in the database has a NOT NULL constraint on it."
I get that this prevents Null values from being entered. But it defaults to blanks or zeros, which overrides my domains when a new feature is created! So someone can add a feature and accept 0 in a field that has a coded value domain, which to some degree defeats the purpose of having the Coded Value domain to force certain values.
What I would like is to force someone to select a value before it will allow the feature to be saved. I thought this was the point of a domain?
Am I missing something or not understanding something about databases? Is this just a limitation, or am I trying to get it to do something that it inherently shouldn't do?
Best Answer
The behaviour you describe is correct. All because you give a field a domain and set field to not allow NULLS does not mean that ArcMap will capture the fact they the user may not touch that field during editing. So when they save edits they can insert a nothing even though you have a domain.
There are 2 routes here: