Select to view content in your preferred language

Related Data Challenges - Please Put Me Out Of My Misery

539
2
10-17-2023 11:10 AM
Labels (3)
JoeMaster
New Contributor

Hi there, literally been going in circles and could really use a hand. New to this stuff and struggling with arcade and utilizing the related tables. 

Here's my setup:

- Devices (point layer) holding static attributes of devices for various customers, marked on the map

- Device Inspections (related table) holding dynamic inspection information for ongoing inspections of each device

- Relationship Class:
-- input table and field: Devices, GlobalID

-- destination table and field: Device Inspections, GUID

-- class name: Arcgis pro = PestIDeviceInspections / alias: Pest Device Inspections. On the tables I see locked fields added named "Device Inspections" and "Devices" respectively 

 

What I need to do:

- Beyond pulling the static values of each Device into the popup, I need to summarize data from each features related inspections. Ie. "Total Inspections" "Total Inspections Passed" Total Inspections Failed" 

- Not only do I need these values to accompany the static information in the popup, but I also need the sum/average values of the related inspections to dictate the symbology of the Devices markers

- Additionally, I need to filter the experiences based on CustomerID. As the extent of the map changes it filters the list and table widgets fine, but the corresponding indicators showing the summarized data do not changed based on the selected features.

I have been messing around with tutorials, chat gpt codes, forum suggestions and I just can't get this to work. 

Please help! I have money if someone can jump into my project and help implement this. 

Thanks!

 

 

0 Kudos
2 Replies
RyanBohan
Frequent Contributor
0 Kudos
MobiusSnake
MVP Regular Contributor

I don't know of a way to have these values calculated automatically as device attribute values (at least until ArcGIS Online supports Attribute Rules) but you've got a few other options:

  • Someone else has mentioned using Arcade to calculate values dynamically in pop-ups
  • You could do all the calculations and filtering using Dashboard widgets
  • You could build a Python notebook and run it on a schedule, recalculating parent values as new children arrive (new inspections could go into an isolated state until the script finds them, so the data won't be inconsistent between the time the inspection is submitted and the time the script runs)
  • You could use webhooks and some kind of serverless function (e.g. Azure Functions, AWS Lambda) to trigger recalculation on the parent record whenever a new inspection is submitted
0 Kudos