Creating relationship class in ArcMap 10.2

The post will demonstrate how to create relationship classes using ArcCatalog in Arcmap 10.2


Thing to note

– Relationship classes can only be created within Geodatabases just like subtypes and attribute domains. User must create a geodatabase to put the contents of the project in.



Let us have a close look at the data available for the demonstration.

On the Table of Contents in green box, there are the layers- Schoollocations and OyoLGA. Schoollocations are point features that are representing schools within the extent of the map. OyoLGA is a polygon feature representing the boundaries of the local administrative units in the same geographical extent. The purpose of the demonstration is to create a relationship class that will summarize the data on schools according to the local government area in which they are located. By calling up this relationship class in ArcMap, the attribute data on schools within a local government area can be easily listed on a Table.



First a Spatial Join between the Schoollocations (Point features) and OyoLGA (Polygon features) was done using ArcToolBox. The Attribute Table of the layer created from the Spatial Join is exported to the geodatabase as a Table called  TableLGA. See the red box in the Catalog window. Our Geodatabase for the demo is named- relationshipclass.mdb.



An important start is to have a look at the attribute tables of the layers that are to be related to identify a common field they share. For the demo, OyoLGA layer has the ID_2 field showing the ID of each local government area.


The TableLGA table also has the field ID_2.



To create the relationship class, Right Click on the Geodatabase > New > Relationship Class



In the New Relationship Class dialog window, Fill in a name for the relationship class. The demo relationship is between the polygon layer representing local governing areas and the Point layer= schools.

OyoLGA is the origin table and tableLGA is the destination table. Click Next. – select the relationship type that would be shared (L-R) 2nd screenshot. For the demo- Simple (peer to peer) relationship is selected.


Capture-4    Capture-5


Next page, for demo- Both is selected             Next page, One to Many relationship as one local government area can contain many schools.

Capture-6      Capture-7


Choosing Yes will allow the relationship class to update anytime more data is added to the attribute table.

In the screenshot to the right, we will select the fields that would form the Join between the two attribute tables. For the demo as shown earlier- ID_2

Capture-8    Capture-9


The relationship class (underlined in red in the Catalog pane)– SchoolsLGA is now created in the geodatabase.



To use the relationship class between the Local government area and the TableLGA, click on a point feature on the map. Once a Point feature is selected, the local government area should also become highlighted.  This indicates that a relationship exists.



To view the schools and their attributes, Right Click on the feature layer > Open Attribute Table



Click on the icon (red boxed). the relationship class will show up. Click on the relationship class and the table should show the results.



When User clicks on the local government area feature, the relationship class Table shows the schools in that local government area.



Also on the TableLGA, when user will open the attribute table and use the relationship class icon as done earlier for the OyoLGA layer. Go to the map and click on a Point feature, the list of features in that local government area is displayed on the attribute table of the selected layer.



Relationship class gives the user the ability to summarize data on an attribute table.

Thank you for reading the blog.


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s