Multiple orders in one pdf


Hey folks,
So I am trying to get a single pdf with multiple work orders. I am able to get the xml with the multiple work orders together.
I am breaking on each work order number as well, and therefore use the for each on : order number in the BI Publisher body.

I am able to get individual work order's data (e.g pg 1-5 first Work order (321262), pg 5-9 second work order (321285)).

The problem I am facing is that the footer is only showing the data from the first work order. It never changes. I want it to change when the work order number changes from 321262 to 321285. I want the work order number to print in the footer. So the first 5 pages footer should show 321262 and the pgs 5-9 footer should show 321285.

I've tried a lot, am calling a subtemplate made specifically for the footer from within the footer, but it doesn't seem to work.

Any ideas?
Update: I have found the solution - bursting. It automatically assigned the corresponding WO in the different pdfs.