Is it possible to target multiple related tables of an existing service?

320
2
Jump to solution
02-20-2024 11:14 PM
ChristopherCounsell
MVP Regular Contributor

Hi,

I publish a survey as:

  • Geopoint
    • Table 1 (repeat)
    • Table 2 (repeat)

I then publish a second survey targeting the existing service with the intention of using a custom url to pass the point globalid and add records to the tables. I want to populate both Table 1 and Table 2 in the one survey.

  • Table 1
  • Table 2 (currently a repeat in the form, to recognize as second table)

This works well for one table, but having two tables gives issues like:

  • two 'parentglobalid' fields needing to be present/populated from the custom url parameter
  • Error 'Destination relationship not found for table'
  • Error 'parent layer not found for table'

These seem reasonable with how repeats are used within survey design. 

I believe I can bypass these issues by having table 2 be nested when first publishing and creating the hosted feature layer. But then I believe Table 2 won't have a direct relationship to the geopoint layer, but to Table 1? This is an issue later as we want a globalid-parentglobalid relationship between the Table 2 and the Layer for other surveys and mapping. I could add a custom guid field to store the layer globalid in Table 2 so it ends up like this:

  • Layer (globalid)
    • Table1 (globalid, parentglobalid)
    • Table2 (globalid, parentglobalid [Table1], customguid [Layer]

Is it possible to submit against both tables but maintain the global/parentglobalid between the layer and table 2?
If not, is it possible to create an additional relationship class between the Table2 customguid and Layer globalid? Any comments on the +/- of doing so?

Otherwise does anyone have any good insight, suggestions or resources on working with relationships/guids with multiple repeats and targeting existing services?

0 Kudos
2 Solutions

Accepted Solutions
ZacharySutherby
Esri Regular Contributor

Hello @ChristopherCounsell

Based on 

  • Geopoint
    • Table 1 (repeat)
    • Table 2 (repeat)

There's no relationship between Table 1 and Table 2, to support a survey that points to Table 1 and includes Table 2 as a repeat the parent survey needs to be: 

  • Geopoint
    • Table 1 (repeat)
      • Table 2 (nested repeat)

 

Thank you,
Zach

View solution in original post

ChristopherCounsell
MVP Regular Contributor

Thanks @ZacharySutherby . I'd hoped for a world where I could keep the globalid/parentglobalid relationship consistent between the two tables and the geopoint layer.

I ended up manually creating the relationship between a custom guid field in table 2 and the point layer globalid field. Also had to recreate the other relationship classes as exporting from ArcGIS Online to Pro and republishing had a bug where the forward/backward labels were dropped so the relationship was called ''. 

While I'm glad there's a functional relationship to use between the point layer and table 2, I'm also hoping there are no more issues after having taken the above workflow...

View solution in original post

0 Kudos
2 Replies
ZacharySutherby
Esri Regular Contributor

Hello @ChristopherCounsell

Based on 

  • Geopoint
    • Table 1 (repeat)
    • Table 2 (repeat)

There's no relationship between Table 1 and Table 2, to support a survey that points to Table 1 and includes Table 2 as a repeat the parent survey needs to be: 

  • Geopoint
    • Table 1 (repeat)
      • Table 2 (nested repeat)

 

Thank you,
Zach
ChristopherCounsell
MVP Regular Contributor

Thanks @ZacharySutherby . I'd hoped for a world where I could keep the globalid/parentglobalid relationship consistent between the two tables and the geopoint layer.

I ended up manually creating the relationship between a custom guid field in table 2 and the point layer globalid field. Also had to recreate the other relationship classes as exporting from ArcGIS Online to Pro and republishing had a bug where the forward/backward labels were dropped so the relationship was called ''. 

While I'm glad there's a functional relationship to use between the point layer and table 2, I'm also hoping there are no more issues after having taken the above workflow...

0 Kudos