Work with Connected Field Arrays in Integromat

Hello,

I am creating and updating some records in integromat and the records I am editing have a connected field where “many” can be inserted. This is the main field that needs to be adjusted by this scenario in integromat.

Basically I have dates, locations and events.

Each record in this object has a date field a location field and then the event field which includes all of the events taking place on this date on this location.

So far I have integromat watching for inserts and checking if that date exists and if the location exists in the same row and if it does it adds that new event to the many field. If it does not it creates a new record.

My issue is that it is replacing the old data in that field. I want it to add that new even to the ones already in this field.

My other issue is similar if they change the date later I have ti set up where it will change it to the correct record or create a new one but it will not remove it from the old one. and will overwrite the current field.

I am new to integromat but not to automation platforms. I was hoping someone could walk me through how to make the IDs a string I can add or remove the new event to and then change back to an array, assuming that is the easiest way to do it?

Thanks so much

Hi

This is a little bit tricky but I have done basically exactly the same as this in Integromat to add or remove users from a list of people ‘liking’ a post in a forum app - here is a screenshot:

This one is triggered by a web hook and ends with sending a response but it will work if triggered in the normal way. Basically this is the process:

  1. Retrieve the record
  2. Use an Iterator to step through all the current entries in the ‘many’ field and then a text aggregator to turn these into a comma separated string:

  1. You will then need a different route dependent on whether you want to add or remove a value and also, when adding, if it is the first value - here are some screenshots which should help:

(to add to a field with values)

Screenshot 2021-10-25 at 09.22.21

(to add a first value)

Screenshot 2021-10-25 at 09.23.07

(to remove an entry)

I hope this helps?

Julian

2 Likes

Thanks so much, it was the split function to recreate the array I was missing. Going to try this and hopefully get it working!

Edited to add, I got it working, thanks again so much.