locked
Report batching RRS feed

  • Question

  • User-228551200 posted

    This is an issue I have been having with SSRS for years.  There is no way I can find to properly 'batch' reports, and this is essential in a business environment (which is why I'm puzzled there seem to be absolutely no provisions for this).  For instance, I have a detailed purchase order report, with company logo, repeated header per page, page m of n, etc.  It works nicely as a single report.  Compromising on the format is NOT an option.

    What if I want to print 5 reports, purchase orders #1000-1004.  I can make another report which calls this as a subreport, and that works, but I lose the page header / footer and pagination.

    I can do it all within a single report, and use groups to provide headers and footers and page breaks, but the formatting is much less flexible and I still lose pagination.

    Right now my "compromise" is to use groups for headers and footers, I would like to add custom code to paginate (set to 1 when group header starts, increment when page ends, this way I can implement page numbering for multiple reports).  So I put some code in 'the' code window under report properties, a variable called "GroupPage" and public subroutines to increment and reset it.  Now I can't find any place I can INVOKE this code.

    At this point, I'm stuck.  (And biting my tongue.)

    Friday, October 28, 2011 3:46 PM

All replies

  • User1654722353 posted

    Hello,

    You can try out below trick.

    1. Add a new blank report

    2. Add a tablix to it and set its top and bottom margin to 0

    3. Place a subreport in it.

    4. Parameter of the subreport should me the purchase order no.

    5. Execute a Stored procedure in main report which returns the purchase order no# 1000 to 1004.

    This way you can get batch report. and also the sub report remains the same.

    I implemented this way in my project.

    For more query reply here...

    Tuesday, November 15, 2011 11:58 PM
  • User-228551200 posted

    When you include a report as a subreport, it strips the page header and footer.  The problem is with the pagination.  But now I have SQL 2008 I will eventualy rewrite the report and try the new pagination feature.  It's still not properly batching reports - I have to warp the report logic and use group headers for page headers, etc.  But at least it's a workaround.

    Wednesday, October 17, 2012 7:26 AM