Table of Contents

Copy a Record Using Record Rules

Lesley Updated by Lesley

Scenario

This article will walk you through how to setup the option to copy records in your Live App using record rules on a form.

Requirements

If this your first time creating an app, you'll need to know some basics about adding tables, fields, pages, and views. You can start by reading our Builder Basics section

Other good resources can be found in our About Your Database and Working With Pages sections of the knowledge base.

Steps

Add a Self Referencing Connection

Add a connection field connecting the table that contains the records you want to duplicate to itself.

This will be a connection to the same table.

In this example, Employees are tracking their Hours, and we want them to have the option to copy previous Hours. We're adding the connection field on the Hours table to the Hours table:

Add a Form

On a details page that displays the specific record you want to copy, add a form view for updating that page's record.

In this example, we're adding a new form for updating the Hours record on the Hours details page. We’re calling the form: “Copy Record”.

We want this form to have no fields, since we want to access the record rules only:

You can also update the submit button text to "Copy Record" and remove the form title.

Add a Record Rule

Go to the the Form Rules section of the view editor for that form and select the Record Rules tab.

Create a new record rule to insert a new record connected to this record. Assign the fields you want to duplicate and set them to inherit the form value of the same field.

Congratulations! You can now duplicate your records.

Notes

Action links have an option to trigger actions similar to record rules.These can also be used in other view types to insert a connected record and copy a record. You can read more about using Action Link triggers here.

Copy Records in Tables

Record rules are also available in grid views that have inline editing enabled. You can read more about using record rules with grid views here.

How did we do?

Track Which User Last Updated a Record

Track When Records are Created and Updated

Contact