How to make sub-jobs

We have an issue when submitting Maya jobs where we have to submit a new job for each render pass in the Maya scene. I’d like to modify our internal submission tool so that it will submit one mater job with sub jobs for each pass. I’ve seen something similar with other software but I can’t for the life of me remember which one. So I’m looking for a little guidance in where to look for examples of this.