---
schema_version: "1"
id: c8928ec2dbe8dd66b2d4f4fefc2f324307399dd6b281a2c11e85534623db4107
title: Update Root Object Field Values When Cloning
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/ind/264-0-0/comms_update_root_object_field_values_when_cloning.md
canonical_url: https://help.salesforce.com/s/articleView?id=ind.comms_update_root_object_field_values_when_cloning.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 664524eae70c95ad8e341c2c5c2d058cf4cc93f34d9cfabd16cf08f7252d300d
description: Use targetFieldUpdates to update field values on the root object in the cloned record and handle Salesforce restrictions on certain field values when cloning a record.
products:
  - Communications
release: "264"
---
# Update Root Object Field Values When Cloning

Use targetFieldUpdates to update field values on the root object in the cloned record and handle Salesforce restrictions on certain field values when cloning a record.

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition"><colgroup><col style="width:100%"></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in:</td></tr></tbody></table>

For example, Salesforce prevents cloning an Order with its status as Activated. Provide a Draft status value in targetFieldUpdates for a successful clone.

![Note](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-ind-communications-264-0-0-production-enus/444efb86-ea1e-477e-afbc-56eaac192eaf/images/icon_note.png)

Note targetFieldUpdates applies only when cloning to a new record. If you specify a targetRecordId, Salesforce restrictions still apply.

The following partial JSON example shows how to update root object field values on the cloned record:

```
{
    "recordId": "801Hs000005meynIAA",
    "sObjectName": "Order",
    "executionMode": "sync",
    "runPricing": false,
    "runValidation": false,
    "targetRecordTypeDevName": "EnterpriseOrder",
    "targetFieldUpdates": {
        "Name": "Cloned Enterprise Order",
        "Description": "Order cloned with status update",
        "Status": "Draft"
    }
    "objectDetailsInSortedOrder": [
        {
            "objectName": "Order",
            "className": "B2BCmexCloneImpl",
            "filterFieldName": "Id",
            "filterOnObject": "Order",
            "dependentFields": []
        }
    ]
}
```