Ad

Getting "INVALID_FIELD_FOR_INSERT_UPDATE" Error Message When Try To Update Salesforce Contact Objet Via Java(EnterpriseWSDL)

- 1 answer

I tried to update Department field in Salesforce Contact object. I got this error response : "INVALID_FIELD_FOR_INSERT_UPDATE 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".

When I tried the Opportunity object(Fields : Amount, stageName), the update succeeded.

I checked the field security levels on both objects' fields. Security levels are same but I am not able to update the Contact object. Could anyone help me with this issue? Stage(opportunity) field access levels - Department(Contact) field access levels

Ad

Answer

The error message indicates "Unable to create/update fields: Name" not the department field. The name field on contact is a read-only field computed from lastName & firstName fields, you can't send it in an update request. You need to update your code to just send the fields you want to change.

Ad
source: stackoverflow.com
Ad