December 9, 2015

@ReadOnly annotation in Salesforce

The @ReadOnly annotation allows you to perform unrestricted queries against the database. All other limits still apply. It's important to note that this annotation, while removing the limit of the number of returned rows for a request, blocks you from performing the following operations within the request: DML operations, calls to System.schedule, calls to methods annotated with @future, and sending emails.

Only WebService, RemoteAction, or Schedulable.execute() methods can be marked read-only.

For more information, check the below link


No comments:

Post a Comment