Hitachi Vantara Pentaho Community Forums
Results 1 to 4 of 4

Thread: Can't get page-break before or after working

  1. #1
    Join Date
    Mar 2010
    Posts
    8

    Question Can't get page-break before or after working

    Hi guys,

    I have searched the forums and googled to find a answer to my question but no luck so far so I hope this is the end of my quest.

    I have a simple problem : I have a main report which, in the "Details" section has many subreports embedded as inline ones. I just want to have each of these subreports on their own new page by using page-break before and page-break before properties.

    I tried setting these properties on the subreports themselves but it didn't work. I tried on many other elements but it didn't change a damn thing. However, the "avoid page-break" property seems to be working flawlessly.

    While searching on the forum, I got 2 ou 3 cases that looked similar to mine but each time, it involved "groups" which I dont have in my reports (also, the explanations given to solve these cases confused me a little ).

    Can anyone please give ma simple and concrete example of using groups within a report? Are "groups" used like sql "group by" clause? I just don't get what groups are supposed to do

    Thanks in advance for your help!

  2. #2
    Join Date
    Mar 2003
    Posts
    8,085

    Default

    Make sure your subreports are banded subreports. Then you can set pagebreaks on the subreport's report-header.

    Inline subreports cannot have pagebreaks (unless they sit in block-layout bands with no intermediate other layout-types inbetween).



    Groups are similar to the SQL-group-by - with the small difference that in reporting groups you can still see the detail rows. When using groups in the report, you have to make sure your data comes back from the database sorted according to the grouping you want to use in the report.

    The samples shipped with PRD use groups a lot.
    Get the latest news and tips and tricks for Pentaho Reporting at the Pentaho Reporting Blog.

  3. #3
    Join Date
    Mar 2010
    Posts
    8

    Default

    Ok thank you for your answer.

    As for my subreports, I choose banded first but when I noticed that you could only place element before an banded and nother after, I finally switched to inline.

    So I guess the solution is to use banded subreports and begin with the latest so I can put the other before it?

  4. #4
    Join Date
    Mar 2010
    Posts
    8

    Thumbs up

    Problem solved! I changed my inline subreports for banded one and I was able to add banded subreports one after the other normally. Seems though that If you add a banded report and try after that to drag and drop a new element, it will be placed before it.

    Anyway, I changed page-break-before property to each of my new banded subreports and it works!

    Thanks,

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.