Help

Re: Update Record step to append a record into a list of linked records rather than overwriting existing linked records

3919 0
cancel
Showing results for 
Search instead for 
Did you mean: 
Anthony_Fennell
4 - Data Explorer
4 - Data Explorer

Hi,

I’m trying to use an automated Update Record step to add a new linked record into an existing list of linked records.

Unfortunately I’m finding that when the automation runs, it simply overwrites the field with the new record rather than adding the new record into the existing list.

Is there some way for the automated Update Record step to append a record into an existing collection of linked records?

Thanks very much.

14 Replies 14
Eli_Kent
7 - App Architect
7 - App Architect

Hey @Meredith_Whitfield,

The solution I outlined above has been working perfectly for me thus far. There might be a more elegant solution :man_shrugging:

Anyway, if you have any questions about applying it, let me know. Happy to help.

Hey @Eli_Kent, would love your help! I think I might need a little step by step guidance, if you don’t mind to spend the time.

Eli_Kent
7 - App Architect
7 - App Architect

Hi Meredith,

No problem. I’m happy to have any excuse to procrastinate in learning code lol.

For real, I am a bit unclear about your context. How is the {Post text} field getting populated? Are you asking the automation to search for multiple issues in the same post? Under what circumstances would a post be linked to more than one issue? Are the records linked to going to change for any particular record in [All Posts], or is this a set-it-and-forget it type thing?

I’ve created a mock-up base for your review. There may need to be some changes made based on the answers to the questions above.

The [All Posts] table contains the following fields:

1- {Issue placeholder}: a linked records field that links to [Issues] table and does not allow for linking to multiple records.

2-{All issues for automation}: a formula field that asks two questions. 1. is there content in {All issues} and 2. does the content in {Issues placeholder} already exist in {All issues}. This formula combines all unique records in {All issues} + {Issue placeholder} to create a string that, through an automation, replaces whatever is in {All issues}.

3-{All issues}: A linked records field that links to [Issues] table and allows for linking to multiple records. This is the end product.

As you can see, when the automation finds “food insecurity” in {Post text}, in Step 1, it links to “Food insecurity” from the [Issues] table in the {Issue placeholder} field (overriding whatever was in {Issue placeholder} previously). In step 2, the automation copies/pastes {All issues for automation} into {All issues}. If you wanted, you could add a third step to the automation that would clear {Issue placeholder} after running the first two steps. It’s unnecessary, but might be a bit cleaner if you’re manually interacting with any of those fields.

Again, the solution you need might be a bit different based on your particular requirements. Also, FWIW, I’m pretty new to programming, so, as I said before, totally possible that there are more elegant solutions than this one.

Let me know if you have any questions.

Finally, here’s a diagram of what {All issues for automation} is doing, in case you want to see.
image

Hey @Eli_Kent, sorry it took me so long to respond! Would you be interested in working a few contract hours for my consultancy to help me get this set up, and help me with another automation issue? If you’re interested, shoot me an email at meredith@conspireforgood.com.

MW

Jake_Singer
4 - Data Explorer
4 - Data Explorer

Another solution: set the automation to set the link the other way!