
1 respuesta

Hi,
- You can use the Database.executeBatch(sObject className, Integer scopeSize) method to set the batch size.
- Used Limit and WHERE CLAUSES
- Also, since you are writing Batch Code, you can also try reducing your scope. The standard batch size is 200 records, but you can increase this up to 2,000 or reduce it to, say, 50. If you are querying a lot of records in the Execute method, it might help to reduce the batch size so the total ⌗ records queried per batch is < 50,000.