Skip to main content

Copy values to related records

Copy a value from one record to every record it links to. When a deal closes, Tape sets the sold price and the buyer on the related property for you.

Written by Leo

When records are linked with a relation field, the same facts often live in two places: the deal knows the price, and the property should show it too. This recipe copies values from the record that changed to every record it links to, so nobody updates the second database by hand.

Automation editor for Deals with the trigger When a record is updated and Stage has changed, the filter Where Stage Has changed to Closed won, and the action Update all related records in Properties that sets Sold price to the deal price and Buyer to the buyer name

Note:

  • Existing values are overwritten. Update related replaces the current value of every field you add, in every related record. Fields you don't add stay as they are.

  • Only linked records change. The action works on records linked to the current record through a relation field, in either direction.

What you'll need

  • A database app Deals with the fields Stage (a single select field with the option Closed won), Price (number), Buyer name (text), and a relation field Property that links to the Properties database app.

  • A database app Properties with the fields Sold price (number) and Buyer (text).

  • To build this automation, you need to be a Workspace admin of the workspace the app is in and have Full access to the Deals app.

Copy the deal values to the property

  1. Open the Deals app and click the automations icon at the top right (Create and view automations).

  2. Select New automation, then select When a record is updated.

  3. In the trigger, select the field name and select Stage under FIELDS.

  4. Under And if the following conditions are met, select Add filter. Pick Stage, then Has changed to, then Closed won.

  5. Select Add action → Update related. The step reads Update all related records.

  6. Next to in, select the app the deals link to: Properties.

  7. Select Add field, then select Sold price. In Value, type @ and select the Price field of the deal.

  8. Select Add field again, select Buyer, then type @ and select Buyer name.

  9. Select Create automation.

Tip: Open the action's menu (•••) to find Silent and Trigger automations. Both are off by default. Turn on Silent if followers of the property shouldn't get a notification for every update. Turn on Trigger automations only if the update should start automations on Properties.

The result

The next time a deal's Stage changes to Closed won, every property linked to that deal shows the deal's price in Sold price and the name in Buyer. Open the automation's Runs to see which records the run updated.

Variations

  • Set a status as well. Select Add field, pick Status, then select Set option and Select an option, and choose Sold.

  • Add a comment to the related records. Select Add action → Get related, then Add action → Comment on collected. Collected records are the records an earlier action found. Learn more about collected records →

  • Copy only to some related records. In Get related, change All records to Filtered records and add a condition, then use Update collected instead of Update related.

  • Go the other way. Get related has Outgoing via (records this record links to) and Incoming via (records that link to this one). Use Incoming via to reach records that point at the changed record, or Both directions to reach records on either side of the relation.

Learn more

FAQs

Will this overwrite values someone entered by hand?

Yes! Every field you add to the action is replaced in every related record. Remove a field from the action if people should be able to change it on the property.

Can I run it for deals that are already closed?

Select Manual run, then under Run on choose Selected records, Selected view, Number of records, or All records, and select Save and start run. A manual run changes real records, and it still checks the automation's filters. A manual run has no earlier values to compare with, so Has changed to doesn't match. Remove that filter or use Is Closed won before you start a manual run on existing deals.

Why did nothing change on the property?

If the property wasn't updated, it could be because:

  • The deal isn't linked to a property in its relation field.

  • The Stage didn't change to Closed won in this update, so the filter stopped the run.

  • The automation is Paused.

Are you a developer using the Tape API for automations?

The automation API has its own documentation for developers. Full reference: referenced_records_update in the developer docs →

Still have questions? Find answers and get help from community experts in the Tape community →

Did this answer your question?