I'm fairly new to playing around with attribute rules. I am looking to have a rule that automatically nulls out two fields that store x and y geometry when a feature's geometry is changed. The reason for this is so that I can then run a GP tool later that automatically selects all features with a NULL value and calculates the new geometry for them in decimal degrees. I only want this rule to fire when the geometry of a feature is changed. Here is how I have configured the rule:
Here is my expression:
if (!IsEmpty($feature.Lat)){
return null;
}
If I'm correct, that statement essentially says "If $feature.Lat is NOT empty, then make it Null"
However the rule does nothing. If I go in and edit a point's geometry, the geometry is never set to null.
Am I missing something?
Solved! Go to Solution.
That looks correct to me. The Lat field should be getting nulled whenever you move a point. Maybe you have a conflicting rule or it's disabled? Make sure the rule is firing by returning a test value without the IsEmpty check.
That looks correct to me. The Lat field should be getting nulled whenever you move a point. Maybe you have a conflicting rule or it's disabled? Make sure the rule is firing by returning a test value without the IsEmpty check.
It was a conflicting rule... Good grief! I'm ashamed to admit how much time this oversight cost me. Lol