Home General
New Blog Posts: Merging Reports - Part 1 and Part 2

Using sub reports in older versions...

edited April 2012 in General
?Our payroll software uses a VERY old version of report builder...

I'm trying to create a payslip report which is one page per employee and
then on each page have a number of sub reports that only show data for
each employee on their own page.

At the moment my sub reports show data for ALL employees.

Is anyone able to assist me with this?

Regards,

Tommy



--- posted by geoForum on http://www.newswhat.com

Comments

  • edited April 2012
    Hi Tommy,

    You need to create a master-detail relationship where the main report is
    connected to the master dataset and the subreport(s) are connected to
    the detail(s). A classic example is a Customer/Orders setup linked on
    Customer ID.

    The master query contains unique customer id's (connected to the main
    report).

    CustomerID
    --------
    1
    2
    3
    4

    The detail query contains orders for each customer (connected to the
    subreport).

    OrderID CustomerID
    ------- ----------
    100 1
    101 1
    102 1
    105 2
    109 2
    111 3
    123 4
    124 4

    Take a look at the main reports demo (RBuilder\Demos\1. Reports\...) for
    some great examples of creating master detail reports. Also take a look
    at the following article on data traversal within the report.

    http://www.digital-metaphors.com/rbWiki/Data_Access/Fundamentals/Data_Traversal

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited April 2012
    Hi Tommy,

    How are you linking your datasets? I highly recommend working through
    some of the master-detail tutorials and taking a look at the
    master-detail report demos located in the \Demos\1. Reports\...
    directory. These give you exact instructions on how to create this type
    of report.

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited April 2012
    ?Thanks for your input Nico. As far as I can tell I have linked my two
    datasets correctly with the appropriate Master and Detail settings when
    I linked the two datasets together.

    But alas for each one of my employees I get all the transaction for ALL
    employees.

    Somehow it's not filtering the data when it draws the subreport each
    time. The subreport is in the detail area of my main report.

    Any help you could provide would be greatly appreciated as I must be
    missing something simple...

    As far as I can tell I'm using RB 6.x

    Regards,

    Tommy



    --- posted by geoForum on http://www.newswhat.com
  • edited April 2012
    ?Hi Nico, I am unable to install the report builder demo on my work
    computer so can only work with the report builder that is embedded in
    our payroll software.

    I have taken a screenshot of how I have linked the two datasets and
    uploaded it to...
    https://skydrive.live.com/redir.aspx?
    cid=604068ca83a040ee&resid=604068CA83A040EE!242&parid=604068CA83A040EE!
    170&authkey=!AKWYyGsq7lBlD2g

    The virtualpayslip dataset it the master where I have one row per
    employee and the historicalallowance dataset contains multiple
    transaction rows per employee.

    I have had a good read through the Developers Guide that comes with the
    RB6.x demo install and am pretty sure I've done everything correctly.



    --- posted by geoForum on http://www.newswhat.com
  • edited May 2012
    Hi Tommy,

    We are only able to give support to registered users of ReportBuilder.
    Since you are using a version built into another product there is no way
    for us to know what changes they have made and/or features they have
    made available or disabled. It is the responsibility of the creators of
    the product to provide this information.

    I suggest downloading the Learning ReportBuilder application and taking
    a look at some of the examples it provieds. There are quite a few
    master-detail examples that you could compare your reports to.

    http://www.digital-metaphors.com/download/learning_reportbuilder.html

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
This discussion has been closed.