Reputation: 126
I am trying to make a batch update to Salesforce as part of a data masking project and am getting the error INVALID_FIELD_FOR_INSERT_UPDATE when I try updating fields of a particular custom object via API. Our custom object has a few standard fields and a few custom fields. The custom fields are what I'm trying to update but I keep getting denied.
Each field that I'm trying to update is either Long Text Area(32768) or Text(255). There are no lookups, controlling fields, validation rules, nor are there field dependencies. I am able to make modifications to other objects (Account for example) via the masking process. I am also able to make modifications to the values through the web UI on the values for this custom object. I've tried as members of the API group as well as System Administrator.
Can anyone please point me in the right direction? I don't have access to the source code of the masking tool, but I do have elevated rights in SF. Thanks in advance for your advice.
The exact error: INVALID_FIELD_FOR_INSERT_UPDATE Error message: Unable to create/update fields: Name. Please check the security settings of this field and verify that it is read/write for your profile or permission set.
The funny thing is that I'm not trying to update the field "Name". Name seems to be an auto-number field on the object, but I'm not sure why this field would change value on an update to a different column.
Upvotes: 1
Views: 15946
Reputation: 1
I had a similar issue today, and this was how it was resolved. My exact error below:
OneLogin Error: User failed creating in app. INVALID_FIELD_FOR_INSERT_UPDATE: Unable to create/update fields: ProfileId. Please check the security settings of this field and verify that it is read/write for your profile or permission set.
Fix to the error:
Audit Field Update Settings: Salesforce typically restricts direct access to certain system fields like ProfileId unless specifically allowed. There’s a setting under "User Interface" in the Salesforce setup that allows "Set Audit Fields upon Record Creation" and "Update Records with Inactive Owners" which you might need to enable.
Upvotes: 0
Reputation: 2887
If some one facing the same issue of not able to update the Name column because it has data type as Name.
There are 2 solutions:
Upvotes: 7