Select to view content in your preferred language

AGOL multiple layers single relationship class

949
3
05-09-2018 11:28 PM
JamesRead1
Occasional Contributor

Just exploring Hosted Feature Layer relationship persistence in AGOL.

I have a FGDB PointFC, with a 1:M relationship class to a related table. I have:

PointFC 

ABField (for def qry)

GlobalID (1) (DataType- GlobalD)

Relationship defined GlobalID to Point_FK

RelatedTable 

Point_FK (M) (DataType - GUID)

GlobalID (DataType- GlobalD)

As guidance suggests..

In mxd (or aprx) I have a definition query set on ABField, to create two layers (pointing at the same source FC) which I thought should both 'honor' the relationship class.

On publishing as a hosted feature service to AGOL, and subsequently when using the edit widget to add a related table record:

GlobalID from the source FC is correctly propagated from layer 0 (A) to the related table

GlobalID from the source FC is not correctly propagated from layer 1 (B) to the related table 

So my question is, is only a single layer (source) supported for relationship classes when publishing to AGOL? Will play with other options, but interested in views.

Happy to share the WebApp..

0 Kudos
3 Replies
JamesRead1
Occasional Contributor

Well, working around my own question, using another approach, If I bring the FC into AGOL as a single hosted feature layer, then duplicate the layer in the webmap, the relationships are honored correctly. Still interested to find out why only the first layer (0) (of multiple) published layers honors defined relationships though. Probably a logical explanation out there somewhere?

0 Kudos
KellyGerrow
Esri Alum

Hi James,

This should work. Did you publish relationship classes with this data? If so, please get in touch with tech support to investigate further.

-Kelly

0 Kudos
JamesRead1
Occasional Contributor

Hi Kelly. Thanks for the response. Yes the relationship was published with the data (at least, it exists in the database). Pre-publication, the relationships work fine for the single data 'source' for all layers, in any desktop product. The fact that it is 'published' is demonstrated by the fact that it 'works' for layer 0. It's just the subsequent layers that don't honor the  relationship established in the FGDB, on publication to AGOL. 

0 Kudos