function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
SF OperatorSF Operator 

Unable to update Case

This is my code:

Case cse = [Select id, status, reason
                    From Case  
                    Where id = :this.target.Id
                    limit 1];
        cse.status = status;
        cse.reason = selectedReason;
        update cse;


I can get the values of the Case but when I update it does nothing

SwethaSwetha (Salesforce Developers) 
HI ,Can you setup debug logs to see what cse holds before the update statement? Thanks
SF OperatorSF Operator
Thanks for your fast reply, it holds the correct data, the only problem is with the update
SF OperatorSF Operator
I double checked the code.. Human mistake, thanks for the help Swetha