操作方法
在 ArcGIS Pro 中,可以将字段的所有值替换为默认值。 但是,有时需要仅替换字段的某些值,以提高数据准确性并实现更精细的空间分析。
在本文中,将使用 Arcade 表达式将 Distance 字段中具有单个“0”的字段替换为“1”。 下图显示了具有要替换的字段值的属性表。

if ($feature.<field_name> == '<initial_value>') {
Replace($feature.<field_name>, '<initial_value>', '<new_value>')
} else {
return($feature.<field_name>)
}
Note:
If numeric or date field values are used, remove the single quotes (' ') on <initial_value> and <new_value>.

下图显示了 Distance 字段中的新字段值。

文章 ID: 000031567
获取来自 ArcGIS 专家的帮助
立即开始聊天