Sollicitatievraag bij Nagarro

Can a batch be called from the execute method of another batch apex?

Antwoorden op sollicitatievragen

Anoniem

22 feb 2017

No.. another batch class can be called from a start or a finish method of our batch class. But never from the execute method.

3

Anoniem

8 jul 2018

No

Anoniem

13 mrt 2019

Yes but only from finish method else it will throw a run time error

Anoniem

9 jan 2022

No, We cannot call another batch class from execute method but we can call it from Finish method else it will throw runtime error as async cannot call batch class from start, execute or finish