I'm planning to perform apex batch chaining since I will be working on around 3-4 objects with total records probably crossing 50 millions. I'll be doing something similar to this: How to update 2 objects from batch apex
I want to know:
Will instantiating the batch class in
finish() and performing the batch operation again and again count as a single transaction or, a new transaction will begin every time?
For Ex. if object A has 10000 records,
object B has 20000 records,
object C has 40000 records
At the end of batch operation for Object C, total how many records will be processed in the transaction? - Will it be a single transaction with
Database.QueryLocator returning 70000 records? Or, will there be three different transactions with
Database.QueryLocator returning 10000 records in 1st, 20000 in second, and 40000 records in 3rd transaction?