Right now I need to schedule a batch call after a existing batch call finishes because I'm relying on the data from the first batch call in the second batch call. Is there a way to call scheduleBatch() after a batch is completed?
Edit: To clarify: I'm pulling a child-parent pair from an object, populating a map with those information, and from that map find the root of each child. Then in the second batch, I will insert the child, parent, root as a single record inside a new Object. We are also not allowed to use external ID so upserting is another challenge. Any help would be appreciated.