• Arun 2
  • NEWBIE
  • 0 Points
  • Member since 2016

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 1
    Questions
  • 1
    Replies
Hi Team,

We are trying to do apexsharing in triggers and webservices for Account Object.We can able to set sharing ID(userId or group Id),but if we set Rowcause is apart from manual its throughing error.
We are getting ​ this exception : CheckRowcause: execution of AfterInsert caused by: System.DmlException: Insert failed. First exception on row 0; first error: FIELD_INTEGRITY_EXCEPTION, field integrity exception: RowCause (cannot insert sharing row with this cause): [RowCause]: Trigger.CheckRowcause: line 14, column 1 .

I have gone through lot of salesforce use cases docuements for this issue. I am properly using my sharing model and also I am using the latest API version i.e 35.0.

Kindly suggest the solution for the same.

Thanks 
Arun.R

 
  • February 09, 2016
  • Like
  • 0
Hi Team,

We are trying to do apexsharing in triggers and webservices for Account Object.We can able to set sharing ID(userId or group Id),but if we set Rowcause is apart from manual its throughing error.
We are getting ​ this exception : CheckRowcause: execution of AfterInsert caused by: System.DmlException: Insert failed. First exception on row 0; first error: FIELD_INTEGRITY_EXCEPTION, field integrity exception: RowCause (cannot insert sharing row with this cause): [RowCause]: Trigger.CheckRowcause: line 14, column 1 .

I have gone through lot of salesforce use cases docuements for this issue. I am properly using my sharing model and also I am using the latest API version i.e 35.0.

Kindly suggest the solution for the same.

Thanks 
Arun.R

 
  • February 09, 2016
  • Like
  • 0