What should the developer do to ensure that users do not overwrite each other’s updates to the same Account if they make updates at the same time?
A developer created an Apex class that updates an Account based on input from a Lightning web component that is used to register an Account. The update to the Account should only be made if it has not already been registered.

What should the developer do to ensure that users do not overwrite each other’s updates to the same Account if they make updates at the same time?
A . Use CastiCase.update(account, false).
B. Add a try/catch block around the update.
C. Use upsert instead of update.
D. Use FOR UPDATE in a SOQL query.
Answer: A
Latest PDII Practice Questions with 280 Q&As
Updated Study Material | Instant Download | Detailed Answers and Explanations
Subscribe
Login
0 Comments