Update multiple parent records when creating new child record? Many to many relationships?

164
1
2 weeks ago
KellyTaylor
New Contributor III

Ok, I know the title makes it sound silly but hear me out here.

Here's my conundrum...

Right now, I'm working on a flight patrol log for a transmission system. I want the user to be able to check off which sections of the system they patrolled during their flight while also updating each section with a new "last patrolled on" and "last patrolled by" (new log entry in a table row, many transmission lines in a feature layer).

One obvious solution is having the log entry be the parent feature with many transmission line children. The problems are

  1. I want the users to update existing transmission lines, not create new ones.
  2. I want the transmission lines to be able to be related to many log entries.
    • BUT I don't want the user to have to open every section of transmission line in an inbox to mark it as having been patrolled (in the case that the transmission line is the parent)

I would prefer the transmission line be the parent as I am ok with the "patrolled_sections" field in the log entry just being a list of section names rather than an actual relationship, so I guess then my question boils down to is there a way to update a field in multiple parent features when collecting a single new child feature? ei each section of transmission selected in a select multiple question in the flight log gets updated with a "last patrolled on" and "last patrolled by"

 

Thoughts? Solutions?

0 Kudos
1 Reply
DougBrowning
MVP Esteemed Contributor

Online or offline?

If online using pulldata("@layer") to the layer could work.  Or I would use the service from the form and look at it in Field Maps using Arcade to do all the lookups.  Or even a Dashboard.

Offline I cannot think of anything since 123 can only run and update calcs when a field is viewed on screen.   You cannot kick off some automated process that changes forms that are not opened by the user.  Even in a repeat you have to scroll through ever one for it to update.  This makes sense really imagine changing a parent field and having 150 repeats kick off a calculation, it would crash the tablet.

Hope that helps

0 Kudos