You need to sign in to do that
Don't have an account?
rksfdc
Too many script statements: 50001
I think this issue is being caused by the code throwing too many debug script than log could handle, has anyone faced this issue before? Is there an easier way or code re-factoring is the only solution?
Code:
System.Exception: Too many script statements: 50001 Class.xx.xx: line 181, column 13 Trigger.: line 52, column 43 Force.com Sandbox Apex script unhandled trigger exception by user/organization: xx/xx xx: execution of BeforeUpdate caused by: System.Exception: Too many script statements: 50001 Class.xx.xx: line 181, column 13 Trigger.xx: line 52, column 43
JimRae
I don't think it is caused by too many debug statements, it is caused by having too many lines of code executing in a loop. I believe the limit is 10,000 script statements per transaction.