+ Start a Discussion

Batch Apex Job- "Job Submitted By"

I have 3 apex jobs which run one by one(Completion of the first job, the second job starts). However the first job is trigger by the Middleware. So, as a result "Job Submitted By" is always shows the Integration User. 
I want to stamp the "Job Submitted By"  by my name. What is the way through which I can meet this requirement. Please suggest. Thanks!

Lokesh KumarLokesh Kumar
HI Kaity,

Correct me if I am wrong, you are saying there are three jobs means three batch apex class so whichever you wants to run as your name got to schedule apex and schedule it accordingly and please make sure logged in user is you.
let me know if you have any questions.

Happy to help you ! 
Informatica is triggering the first batch job. I am not starting the batch job from Salesforce.
Lokesh KumarLokesh Kumar
No. Batch Apex will run as the current user. You should take this into consideration if you have validation rules, etc that might cause problems because of this. The only time you can alter the current running user is when running unit tests, which will not assist you in this case.
it is not possible to assign the batch to a different user at the moment

But it is running in system mode, which means that object level and field level security pose no threat. Just validations and triggers.

an idea is posted for the same : https://success.salesforce.com/ideaView?id=08730000000H11Q

For more check the below link

http://salesforce.stackexchange.com/questions/117009/how-to-schedule-a-job-as-specific-user (#)