[GIS] How to let ArcGIS Server see related records in a geodatabase

arcgis-rest-apiarcgis-serveresri-geodatabaserelationship-class

I have an ArcSDE geodatabase which contains multiple relationship classes.

If I add this layer to ArcMap, the relationship is automatically applied (eg, the Identify dialog allows me to drill-down to the related features).

However, if I publish this map document to ArcGIS Server, the REST endpoints for the layer don't show the relationship classes.

Similarly, if I create a new ArcMap document and create a Relate within ArcMap (using > Joins and Relates in the TOC) this also fails to appear in ArcGIS Server's REST directory.

This sample REST directory does show the related data. How has this been set up?

Best Answer

The only time I have had problems with relationship classes that exist in SDE not being automatically published in a map service was because there is a problem with permissions on the account I was publishing with to see the related table in SDE.

How are you adding related feature classes/ tables to the .mxd? Is it the same user/version as the key feature class and if so is the sde connection file in a location that the SOC and Som accounts have access to?

Note that the related table must be added to the map, as well as being defined in the relationship class..

Related Question