How to convert Esri Shapefile to Geodatabase

Liz Sanderson
Liz Sanderson
  • Updated

FME Version

  • FME 2019.x


In this tutorial, we will be transforming City of Vancouver Postal Code data, from Esri shapefile (*.shp) to Esri file geodatabase (*.gdb) format. During the translation, we will also be creating a new Esri feature dataset container to hold the feature class.

The Esri shapefile (forwardsortationareas.shp) denotes the different postal districts covering Vancouver. A forward sortation area (FSA) is a geographical region in which all postal codes start with the same three characters. The first letter of an FSA code denotes a particular "Postal District".

This tutorial requires a licensed version of ArcGIS installed on the same machine as FME in order to create the feature dataset. If you do not have a licensed version of ArcGIS, you can still follow along by using the File Geodatabase Open API writer but you won't be able to create the feature dataset, only the feature class.



This video was filmed using FME 2016, but the functionality is still the same in newer versions of FME.


Step-By-Step Instructions

1. Inspect the Data in FME

The first step is to inspect the ForwardSortationAreas.shp file. Open FME Workbench and start a blank workspace and add a new reader. In the reader dialog, type in Esri Shapefile as the Format, then browse to the ForwardSortationAreas.shp file for the Dataset. Click OK to add the reader to the canvas.



Now to view the data, click on the ForwardSortationAreas reader feature type on the canvas to open the popup menu. Then on the popup menu click the View Source Data button to view the data in the Visual Preview Window.



We have area features representing the forward sortation areas. There is a single attribute (CFSAUID) which identifies the forward sortation area, which is the first 3 characters of the Postal Code.



Note: This step can also be completed in FME Data Inspector for versions previous to FME 2019. Just be sure to add the Esri shapefile reader to FME Workbench after inspecting the data.


2. Inspect the Data in ArcCatalog

Let's take a look at the CommunityMapping.gdb file in Esri ArcGIS ArcCatalog.

In ArcCatalog, we can see that there are existing feature classes, but no feature datasets. As part of the translation, we will want to add the ForwardSortationAreas feature class to a newly created feature dataset called “Postal”.



3. Set the Output (Writer) Format to Esri Geodatabase

Back in FME Workbench, we need to add a writer to the canvas. Click on the Add Writer and in the Add Writer dialog box, for the Format, select Esri Geodatabase (File Geodb).

Note: If you do not have ArcGIS installed on the same machine as FME, the File Geodb version of the writer will be unavailable. You can instead use the Open API File Geodb version but the option to create a feature dataset will be unavailable.

Then for the Dataset, browse to the CommunityMapping.gdb. Ensure that the Feature Class or Table Definition is set to Copy from Reader and then click OK.



4. Modify Output (Writer) Feature Type Properties

Connect the ForwardSortationArea reader feature type to the new writer feature type. Then open the writer feature type parameters by double clicking on it. By default, the translation creates a new feature class named ForwardSortationAreas within the geodatabase. However, we would like to nest this translated feature class inside of a newly created feature dataset named “Postal”.

First, set the Geometry to geodb_polygon, so the feature class will be the correct geometry. Then to create the feature dataset, expand Table Creation Parameters and then for Feature Dataset type in Postal. Click OK to confirm the changes.



5. Click the Run Button on the Toolbar

Run the workspace by clicking on the green play button. This carries out the translation.


6. View the Feature Dataset & Feature Class in ArcMap

In ArcMap, refresh the view, and you should now find a Postal feature dataset containing the ForwardSortationAreas feature class.



Data Attribution

The Forward Sortation Areas data set provided here comes from Statistics Canada, 2011 Census Digital Boundary Files, 2013. Reproduced and distributed on an "as is" basis with the permission of Statistics Canada. © This data includes information copied with permission from Canada Post Corporation.

Was this article helpful?



Please sign in to leave a comment.