Field Mapping

Since version: 1.7

With the field mapping profile, expressions can be written to define a field map between source and target layers. The field map is used by the transfer attribute tool, copy/paste attributes and other editing tools where a field map can be specified.

Context

The following products implement this profile:

Spatial reference

The spatial reference of the map in which $feature is rendered determines the spatial reference of the expression's execution context.

Profile variables

Variable NameTypeDescription
$sourcefeatureFeatureThe source feature for the field map.
$targetfeatureFeatureThe target feature for the field map.
$sourcelayerFeatureSetA collection of features in the same layer as $sourcefeature.
$targetlayerFeatureSetA collection of features in the same layer as $targetfeature.
$mapFeatureSetCollectionA collection of layers in the map of the executing arcade expression.
$sourcedatastoreFeatureSetCollectionA collection of layers in the same datastore as the $sourcelayer.
$targetdatastoreFeatureSetCollectionA collection of layers in the same datastore as the $targetlayer.

Function bundles

Core | Geometry | Data Access | Portal Access

Return types

Dictionary

Example

The following example copies the values in the source feature fields Elevation and Rotation to the target fields with the same name.

Use dark colors for code blocksCopy
1
2
3
4
return {
  "Elevation" : $sourceFeature['Elevation'],
  "Rotation" : $sourceFeature['Rotation']
}

Your browser is no longer supported. Please upgrade your browser for the best experience. See our browser deprecation post for more details.