Search Results
Search type | Search syntax |
---|---|
Tags | [tag] |
Exact | "words here" |
Author |
user:1234 user:me (yours) |
Score |
score:3 (3+) score:0 (none) |
Answers |
answers:3 (3+) answers:0 (none) isaccepted:yes hasaccepted:no inquestion:1234 |
Views | views:250 |
Code | code:"if (foo != bar)" |
Sections |
title:apples body:"apples oranges" |
URL | url:"*.example.com" |
Saves | in:saves |
Status |
closed:yes duplicate:no migrated:no wiki:no |
Types |
is:question is:answer |
Exclude |
-[tag] -apples |
For more details on advanced search visit our help page |
Issues with writing, running, or testing scheduled Apex code, using the Schedulable interface.
1
vote
Accepted
Apex example Code to copy Account field values
This requirement for you is good exercise as a fresher.
Please use the trailhead module to explore scheduled job and batch apex
https://trailhead.salesforce.com/en/content/learn/modules/asynchronous …
2
votes
Best Practices: Callout retry
I would suggest that you can insert the failed record Id into a separate custom object and also stamp the time your batch started .Then when your batch finishes you can schedule the job on the custom …
5
votes
Accepted
how to complete 100% test coverage for scheduled apex class
You will need to insert Time_of_Account__c record as well as your scheduler queries for the data
Test.StartTest();
//insert test data
Time_of_Account__c t=new Time_of_Account__c();
t. …
8
votes
Accepted
Scheduling a batch process using UI- Which timezone does it schedule on?
The apex developer guide shows that scheduled jobs follow users time zone
The System.Schedule method uses the user's timezone for the basis of all schedules.
The easisest way would be to use a u …
0
votes
Schedule VisualForce Extension and Actions
//Assuming you write a scheduler class as mentioned in scheduler class example
global class scheduledMerge implements Schedulable{
global void execute(SchedulableContext SC) {
}
}
this is …
0
votes
possible to access REST API of another SF instance with portal user from scheduled class?
The portal licence type will decide what you can access and what you cannot.
portal license type will not allow you to access standard objects like other contacts and Accounts.So even if you registe …
4
votes
Schedule apex class to run every minute as there can only be 5 batch jobs
datetime mydate = system.now();
integer d = mydate.day();
integer m = mydate.month();
integer h = mydate.hour();
integer s = mydate.second();
integer min = myda …
0
votes
How to send Weekly Email to email-fields of records?
http://www.salesforce.com/us/developer/docs/apexcode/Content/apex_scheduler.htm
One topic that is necessary to understand the scheduler interface
The other will be to undesrtand outbound email topi …
0
votes
Apex Schedule Job Error - When triggering a Flow
You will need to pass the case Object and have it an ID for update scenario before you invoke the flow. Where are you passing it?
You would do something like below
global class ScheduledFlow implement …
1
vote
Mass Email Alert to Salesforce Users
If you have your security set up properly ,you can try scheduling a Report .Create a report that meets your need with proper filters and assuming you have great security in place ,you can select My op …
3
votes
Accepted
HTTP callouts in Batch Apex
The batch size you can keep is 5 .As thats the maximum no of calls allowed per batch context is 10.
Small example:
String query = 'Select Contact.FirstName,Contact.MobilePhone,Contact.Email,Contact …
4
votes
Accepted
Batch Apex Query - when multiple batch jobs fails
a) It depends on what DML methods you are using
i)Using Database.Upsert will allow you to continue processing all other records of the Batch without failing anything .You have an optional parameter …
3
votes
scheduling a batch class to run every 15 min in managed package
You can use PostInstall script in apex for managed package to automatically schedule the batch apex to run every 2 minutes .
PostInstall scripts run as soon as the installation of your managed packag …
3
votes
Accepted
QueryLocator generates scope of the Object
The scope is of type SObject which can be cast to specific objects (Like Account, Contact, etc).
The querylocator object is described here.
It has two different methods
getquery
Iterator
In Batch …
1
vote
How to write the Test class for a Schedulable class which uses a custom label ( converted to...
Apex allows you to set the CreateDate field, all you need is to use below during data creation,
Test.setCreatedDate(<recordId>, datetimevalue);
In your case, when you are creating the Error log use …