无法在个人客户 SalesForce 中插入记录

Unable to insert record in Person Account SalesForce

我已激活个人帐户并尝试在 APEX 的帮助下插入记录。这是我的代码

Account pAccount = new Account();
pAccount.recordTypeId = '012370000009dFh';
pAccount.FirstName = 'SFDC';
pAccount.LastName = 'Axel';
pAccount.personEmail = 'axel@sales.com';
insert pAccount;
return 'Added'; 

但是当我尝试 运行 时显示以下代码错误:

Error: call to URL https://XXXX.salesforce.com/services/apexrest/v2/setOrder/ failed with status 500, response [{"errorCode":"APEX_ERROR","message":"System.DmlException: Insert failed. First exception on row 0; first error: CANNOT_INSERT_UPDATE_ACTIVATE_ENTITY, entity type cannot be inserted: Person Account: []\n\nClass.RESTCaseController.createNewCase: line 22, column 1"}], curl_error , curl_errno 0

(没有验证问题。) 请帮助我

必须将 Force.com 站点上的 "Standard Record Type Settings" 更改为帐户对象所需的记录类型。他们不需要在插入语句中指定 recordTypeID。

另请确保用户具有对所有模块的适当访问权限。

灰烬