ArcGIS Pro

Upsert your datasets using the Append tool in ArcGIS Pro 3.1

Approximate Reading Time: 6 Minutes

In ArcGIS Pro 3.1, you can use the Append tool to update the records of a target dataset with attributes and geometry from new or updated datasets. This enhancement extends Append from a tool that can load or insert new records into a dataset to one that can also update existing records. In database terminology, this is referred to as an upsert.

What Is An Upsert Operation?

Upsert is a combination of the words “update” and “insert,” meaning you can upsert a dataset by updating existing records and inserting new rows of data.

Upsert illustration
Upsert illustration

Previously, you could only use the Append tool to insert new records from an input dataset to a target dataset. With the new enhancements introduced in ArcGIS Pro 3.1, you can also use Append to update the existing records in your target dataset. This means the Append tool now has the ability to upsert your data.

The following example shows how to use the Append tool to upsert zoning data by updating existing areas with rezoning data and inserting newly annexed areas into the zoning dataset.

Example Scenario

You are a GIS intern for the City of Charlotte, NC, one of the fastest-growing cities in the United States. As the city faces rapid development and growth, your task is to update the city’s zoning data for a forthcoming general plan update.

A current, simplified zoning map of Charlotte, North Carolina
A current, simplified zoning map of Charlotte, NC

Since the last update, the city has undergone significant changes. First, an existing industrial area has been rezoned to a mixed-use area. Second, the city plans to annex a previously unincorporated land area into its boundaries for single-family homes.

Example future rezoning and annexation plans
Future rezoning and annexation plans

Your goal is to find a way to easily update the current zoning data and insert the new areas into the city’s zoning map.

Use Append To Upsert Your Dataset

Using the Append geoprocessing tool, follow the steps below to upsert your zoning data.

First, let’s use the Append tool to insert the newly incorporated zone into the city:

(1) Add the rezoning data into the Input Dataset

(2) Add the original zoning data to the Target Dataset

Caution: This tool does not create an output dataset; it modifies the target dataset. Take precautions if you are unsure you want to modify your target dataset. 

(3) Leave Field Matching Type at the default setting, “Input fields must match target fields,” if the input and target datasets have matching schema and you do not need to reconcile any field differences.

Append tool parameters with steps
Append tool parameters

In previous versions of ArcGIS Pro, you would run the Append tool from here, and the tool would insert the new area and duplicate the rezoned area to the target dataset. However, with the enhancements made in ArcGIS Pro 3.1, the tool now includes the option to update the existing features in your dataset.

Expand the Update Options dropdown to reveal two new parameters to ensure that your attributes and geometry update when you run the tool.

Append tool Update Options
Append tool Update Options

(4) Use the Matching Fields for Update parameter to update existing records in the target dataset based on matching records in the input dataset. In this example, each zoning polygon has a unique Zone_ID. Therefore, any records from the target with a Zone_ID that matches records in the input dataset will update with values from the input.
Note: You can also match based on multiple matching fields.

(5) Check the Update Geometry parameter to update any changes made to the existing geometry.

Run the Append tool.

Result: The New Zoning Map

After running the Append tool, the resulting map includes the updated existing zones and the newly incorporated area into the city.

A quick swipe through the old and new zoning maps shows we have successfully used the Append tool to upsert the zoning dataset.

Animated swipe through showing the new versus old zoning map.
The updated zones versus the original zoning map.

The features where the specified field value, Zone_ID, matched had their geometry and records updated. All other features were appended to the target dataset.

Summary

An upsert operation updates existing records and inserts new records from an input to a target dataset. The Append tool in ArcGIS Pro 3.1 now includes two new parameters you can use to update the attributes and geometry of a dataset. With these enhancements, you can use the Append tool to upsert your datasets.

About the author

Margaret is a Product Engineer on the Geoprocessing team. Her passion for GIS began with her interest in human-environmental relationships, and her graduate studies utilized spatial analysis to study the growing impact of flood-induced cascading disasters caused by sea level rise. Margaret leverages her foundation in research methodologies and spatial analysis techniques in her role at Esri, where she creates written content and demonstrations on technical concepts and functions in ArcGIS Pro. She also contributes to refining and redesigning geoprocessing tools and functions with additional capabilities and improved usability. In her personal life, Margaret is a loving cat parent to three cats, and enjoys swimming and snowboarding.

Connect:
Subscribe
Notify of
5 Comments
Oldest
Newest
Inline Feedbacks
View all comments

Next Article

New! Probabilities in Forest-based and Boosted Classification in ArcGIS Pro 3.3

Read this article