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

How to Structure Report

edited September 2010 in General
I have a application in which I need to generate a report that will have 6
different column arrangements based on the value of one data field. The
report would be sorted by this one data field. When different values in
this sorting field are detected the report needs to change to the
appropriate format. This is like having an Excel spreadsheet with different
tabs of data in different formats. I want to be able to print "all tabs" so
to speak.

How can I structure the report? I have done reports using subreports when I
had a master-detail data arrangement where the master table would be in the
main report and the detail tables would be in the subreports.

But the application I'm trying to complete now is a simple table and I don't
see how I can do it in a subreport.

Any suggestions would be appreciated.

Regards,

Al

Comments

  • edited September 2010
    Hi Al,

    I'm a bit unclear about what exactly you would like your report to look
    like.

    From what I understand, you have a single dataset with an ordering field.
    Is this report going to display a single row of data per page? If you get
    to a certain field value how would you like the report to react? (break to a
    new page and begin a new format?).

    Perhaps a bit more information about what you would like to ultimately
    accomplish and how exactly you would like the report to look would help me
    understand what approach you should take.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited September 2010
    Nico,

    Thanks for the response.

    There is only one dataset. Multiple rows of data per page. If the ordering
    field valve changes, then I want a new subreport to start. (I think of
    using a subreport because the column names (data fields displayed) would be
    different.) Or start a new page with different column headings.

    Regards,

    Al



  • edited September 2010
    Hi Al,

    My first suggestion would be to create a group based on the ordering field.
    You can set this group to break to a new page if needed.

    From here you can now alter the output of the report based on the group
    break value. See the AfterGroupBreak and GetGroupBreakValue events.

    As a side note, it could also be beneficial to manually create a master
    detail relationship out of the single dataset you are using. If for
    instance, you created a query that simply selected all the distinct ordering
    records you could make that the master and link it to the original dataset
    which would act as the detail. This way you could use subreports which may
    make things easier.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

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