I am creating a jasper report with some very specific requirements. The report contains a group.The group header must print at the beginning of the group and also on a new page. The detail section is not allowed to split across a page.The group header must not print at the bottom of a page unless at least one detail section will fit. (Could be rephrased as: The group header must only print when at least one detail section will fit) The detail section is dynamic height.I have tried using "Keep together" on the group, but that can leave too much blank space on pages if the first group is small, but the second is large. It was rejected as a solution. With these requirements in mind. All I am trying to do is not print the group header when the page cannot fit any detail entries. I suspect that when it is filling in the report that it probably doesn't know the height of the detail section until it has filled it in, and by then it is too late. I'm hoping I am wrong. I have tried recreating this report in two ways: One report with a group and detail sections.A main report with a subreport for the group, and within the subreport another subreport for the detail.Both ways have led me to the same results. Visually, if this was my data: Province - Ontario City - Ottawa City - TorontoProvince - Nova Scotia City - Halifax City - New GlasgowProvince - Quebec City - Montreal City - Quebec City I might get this result: Page 1Province - Ontario City - Ottawa City - TorontoProvince - Nova Scotia City - Halifax City - New GlasgowProvince - Quebec <- This hanging header is unwanted Page 2Province - Quebec City - Montreal City - Quebec CityI have tried many permutations of settings, placing the subreports in different bands, but I haven't found something that works. I am hoping someone knows of a combination of settings, placing subreports in different bands, etc. that will work. Any idea how I might accomplish this?