**Source URL:** https://limited.veevavault.dev/quality/mdl/component-types/relatedrecordsetup

# Relatedrecordsetup

**Class:** `metadata`

Admins in Quality Vaults can configure object lifecycles to automatically create a new, related object record when the source object record enters a specific lifecycle state by adding *reate Related Record* entry actions. The `Relatedrecordsetup` component defines a *Related Record Configuration*, which Admins use to define source and related objects. Each `Relatedrecordfieldvaluemapping` subcomponent represents single *Field Value Mapping*, which Admins use to map fields between the source and related objects. Each `Relatedrecordreferencemapping` subcomponent represents a single mapping between a source reference record and a target reference record.

Learn more about [Related Record Configuration in Vault Help](https://quality.veevavault.help/en/lr/74249).

| Attribute | Metadata | Description |
| --- | --- | --- |
| `label` | Type: String Max length: 60 | UI-friendly string in the Vault’s base language. |
| `active` | Type: Boolean | Indicates whether the component is active. |
| `copy_attachments` | Type: Boolean | If `true`, reference object records from the source object are automatically copied to the target object when the *Create Related Record* entry action executes. |
| `description` | Type: String Max length: 1500 | A description of the *Related Record Configuration* to display in the Vault Admin UI. |
| `outbound_reference_field` | Type: Subcomponent **Required** | The object reference field on the related object record to be created, which references the source object. |
| `related_object` | Type: Component **Required** | The object that will be created by the *Create Related Record* entry action. |
| `related_object_type` | Type: Component **Required** | The object type, if the related object allows object types. |
| `source_object` | Type: Component **Required** | The source object on which the *Create Related Record* entry action will be configured. |
| `source_object_type` | Type: Component **Required** | The object type, if the source object allows object types. |

### Relatedrecordfieldvaluemapping

| Attribute | Metadata | Description |
| --- | --- | --- |
| `label` | Type: String Max length: 60 | UI-friendly string in the Vault’s base language. |
| `active` | Type: Boolean | Indicates whether the component is active. |
| `mapped_source_object_field` | Type: Subcomponent **Required** | The field on the source object to be mapped. |
| `mapped_source_reference_object` | Type: Component | If the field value is to be derived from a field on a record related to the source object, this represents the object on which that field exists. |
| `mapped_source_reference_object_field` | Type: Subcomponent | If the field value is to be derived from a field on a record related to the source object, this represents that source record’s related record field. |
| `related_object` | Type: Component **Required** | The object that will be created by the *Create Related Record* entry action. |
| `related_object_field` | Type: Subcomponent **Required** | The field on the related object to be mapped. |
| `source_object` | Type: Component **Required** | The source object on which the *Create Related Record* entry action will be configured. |

### Relatedrecordreferencemapping

| Attribute | Metadata | Description |
| --- | --- | --- |
| `label` | Type: String Max length: 60 | UI-friendly string in the Vault’s base language. |
| `active` | Type: Boolean | Indicates whether the component is active. |
| `source_object_field` | Type: Subcomponent **Required** | The primary parent object field from the source object used to derive matching target reference join objects. |
| `source_reference_field` | Type: Subcomponent **Required** | The secondary parent object field from the source reference join object used to derive matching target reference join objects. |
| `source_reference_object` | Type: Component **Required** | The source reference join object matching on primary parent object field `source_object_field`. |
| `target_object_field` | Type: Subcomponent **Required** | The primary parent object field from the target object used to derive matching target reference join objects. |
| `target_reference_field` | Type: Subcomponent **Required** | The secondary parent object field from the source reference join object used to derive matching target reference join objects. |
| `target_reference_object` | Type: Component **Required** | The target reference object matching on the primary parent object field from the target object and secondary parent object field from the source reference join object. |

### Supported Operations

| Operation | Support |
| --- | --- |
| Create | Yes |
| Recreate | Yes |
| Alter | Yes |
| Drop | Yes |
| Rename | Yes |
| Describe | Yes |
| Generate Recreate | Yes |
| Queryable | Yes |

---

**Previous:** [Recordworkflowaction](/quality/mdl/component-types/recordworkflowaction)  
**Next:** [Renditionprofile](/quality/mdl/component-types/renditionprofile)