A common scenario that one may encounter when working with File Geodatabase is to receive a set of data which contains changes to the features and attributes of feature classes in an existing File Geodatabase. The following example will show how to use Geodatabase functionality in order to update existing Geodatabase features with an edited Shapefile dataset.
In the above image, we see a visualization of the original/destination feature class showing the current and required location of three drinking fountains.
In the above image, we see a visualization of the updated Drinking Fountains Shapefile and its accompanying attributes.
1. Create Destination File Geodatabase
Using the update functionality of a File Geodatabase assumes that the destination Geodatabase to be updated already exists. For purposes here, an XML workspace document has been provided so that the required File Geodatabase needed for this example can be imported into ArcGIS. In order to do so, within ArcCatalog or ArcMap, create a new, empty File Geodatabase. Once created, download the provided XML template file (refer to downloads section) and import the template into the empty Geodatabase as an XML workspace document (select the Import Data option).
2. Read Source Data
Drinking fountain geometry is read from the Shapefile source file with the ESRI Shape reader. This Shapefile contains the updated feature location for the three drinking fountains that are misplaced in the destination feature class.
3. Update Maintainer Attribute
The AttributeManager will be used used to update the value of the "Maintainer" attribute from that of the Parks department to the Engineering department as you received additional information from management indicating that the responsible department for maintaining those particular drinking fountains has changed. Connect the Shapefile reader to the AttributeManager and in the AttributeManager properties, simply type "Engineering" for the Attribute Value of the Maintainer attribute. You will notice that the Action for the attribute will automatically switch to "Set Value".
4. Update Original Feature Class
Add the ESRI Geodatabase (File Geodb API) writer to the workspace. For the writer dataset, navigate to the Geodatabase created in step 1 and for Feature Class or Table Defintition, select "Import from Dataset". The Import from Dataset option is selected because the feature class already exists in the Geodatabase and we intend to update it.
When prompted, set the format and select the File Geodatabase as noted in the paragraph above (it may – should – already be set by FME). FME will now scan the Geodatabase to confirm what tables exist. When prompted with a list of classes, select DrinkingFountains only.
Once the writer has been added to the canvas, double click on the writer feature type to enter the Feature Type Properties dialog. Click the Format Parameters tab and type "FountainID" in the Update/Delete Key Fields section.
Save and Run the workspace and inspect the DrinkingFountains dataset. You should now find that the erroneous drinking fountains have been moved into the correct position. If you can’t find the new drinking fountains, they should be located close to the following locations (coordinate values are in UTM):
||X Coordinate||Y Coordinate|
3 People are following this .