You need to sign in to do that
Don't have an account?
surya kanadhipatla
Community user(profile) not able insert the case team member using trigger(getting exception)
Hi All, Good afternoon...
We have implemented a trigger to associate case team memebers to a case created via communities..
This trigger works fine for internal users but when users with community user profile creates a case its throws following error:
Op:Insert|Type:CaseTeamMember|Rows:1
System.DmlException: Insert failed. First exception on row 0; first error: OP_WITH_INVALID_USER_TYPE_EXCEPTION, Operation not valid for this user type: []
I have verified community user profile does have read/write access to case object and able to create the cases as well.
Even tried without sharing key word still exception.Observed the exception when caseteammember is inserted.
If i comment out the insert caseteammemebr line in trigger helper class no exception and case was created without case team members...
Any Help will be appreaciated...
We have implemented a trigger to associate case team memebers to a case created via communities..
This trigger works fine for internal users but when users with community user profile creates a case its throws following error:
Op:Insert|Type:CaseTeamMember|Rows:1
System.DmlException: Insert failed. First exception on row 0; first error: OP_WITH_INVALID_USER_TYPE_EXCEPTION, Operation not valid for this user type: []
I have verified community user profile does have read/write access to case object and able to create the cases as well.
Even tried without sharing key word still exception.Observed the exception when caseteammember is inserted.
If i comment out the insert caseteammemebr line in trigger helper class no exception and case was created without case team members...
Any Help will be appreaciated...
How about changing the case owner to a full license user and try adding the case team?
Any way we have assignment rules which kicks in after that and case owner changes again accordingly....
Waiting for your reply to see any side effects....
All Answers
@Rahul, you are right but is there any work around?How did you resolve it?
@Abhi,I tried WithOut sharing but did not work (It could be the reason Rahul mentioned above).Looking for other work arounds..
We have already raised SF support case, but they are far behind us...:)
I want to take this route if SF support does not provide any other solution(work around) and let you know...
Much appreciated...
How about changing the case owner to a full license user and try adding the case team?
Any way we have assignment rules which kicks in after that and case owner changes again accordingly....
Waiting for your reply to see any side effects....
I'm trying to add the community user contact to a case team when the user writes a comment to an existing case. I'm getting the same error saying that users with the community license can't insert CaseTeamMember objects.
That is a restriction in the CaseTeamMember object. I don't understand how changing the case Owner could change that. In our Salesforce organization, case Owners are always either support members or a queue.
Do you know any way to insert the CaseTeamMember as a community user?
Thank you.