[#9667] - sortField produces strange behaviour of groups printing

Category:
Bug report
Priority:
Normal
Status:
Feedback Requested
Project: Severity:
Minor
Resolution:
Open
Component: Reproducibility:
Always
Assigned to:
0

Hi,

When adding a sortField tag to my Jaspersoft report, it produces a strange behaviour of the groups display. More precisely scheme is :
<field ..>
<sortField ..>

<group 1>
<groupHeader>
display some imamges
</group>
<group 2>
<groupHeader>
some static texts
</group>

<detail>
display the dataset

Detail section display the dataset sorted, so it is okay, but the group 2 will be displayed over all pages, even where the images of group 1 are displayed. I think it is a bug of the sortField tag. If it is not, please explain to me the way to do it right.

Thanks,

v6.3.1
geoffrey.dabert's picture
Joined: May 24 2017 - 3:01am
Last seen: 2 months 3 weeks ago

1 Comment:

#1
  • Status:New» Feedback Requested
  • Assigned:» teodord

Hi,

It would be good to see your report template and some output produced by it in the form of a PDF.
But what I can tell you right away is that groups break every time the value of their expression changes. Groups do not perform any sorting and rely on the order of records as returned by the data source or produced by the sort field definitions.

In other words, your group headers appear all over the place because the groups break very often, probably with every record. This is because your sort order does not match your group structure.

For example, if you group customer orders by country, you better make sure your records are sorted by country in the first place, otherwise you end up with the France group appearing many times.

I hope this helps.
Teodor

Feedback