Automation to update linked records is replacing existing linked record, not adding to it

Hi there.

I have an automation that does the following:

  1. When a new 'Billable Hours' app record is created

  2. Find the record in the 'Invoices' app that matches the date range and client

  3. Update the 'Billable Hours' linked records field in 'Invoices' to include the 'Billable Hours' record that was just created

The aim is to then create invoices for each client, each month, with all of the billable hours listed as line items.

The automation works but each time it runs it doesn't add the linked record and create a group/list/array of all the linked billable hours records, it just overwrites what was there before. So I create a new 'Billable Hours' record, the automation fires and populates the 'Billable Hours' linked records field on 'Invoices' correctly, but when I create a second 'Billable Hours' record, it removes the link to the first one and replaces it with this new one. I want it to add links all records that are created that fit the conditional, not only the latest record.

Is this possible?

Thanks!

Mat

5
4 replies