Solved

crystal reports 2011 Sub reports / loops

Posted on 2014-03-20
9
394 Views
Last Modified: 2014-11-27
Crystal report 2011
CR Developer
Version 14.0.4.738 TRM

I have a report that has a main report with a page header defined. The main report is used to select the input parameters.  The main report calls 6 sub reports; each sub report is defined in its own separate report footer.  Three of the sub reports are cross tab reports.   The main report does not use the detail section.

The user selects a set of parameter for the report. These parameters are displayed as part of the page header.

The user now wants to be able to do a select of “ALL” on one of the input parameters.  The idea is to generate a concatenated report.  So the header and six sub reports would execute for the first item in the list, the next item and so on. The list can be controlled by a data base select, so the user only selects the ALL item.

I have done this before by converting the main report to a sub report and then calling the subreport  in  a group by detail section detailed section.  But in that case the main report did not have call to a sub report.

I know that subreports cannot call subreports (if it could it would simplify this problem).

Any idea on how to do this with such a complicated report?
0
Comment
Question by:fpkeegan
  • 4
  • 2
9 Comments
 
LVL 18

Expert Comment

by:vasto
Comment Utility
I don't think that this is possible because you have subreports. If you can place the subreports in the details section and use groups to handle the printing then obviously it is a matter of providing the list of the parameters.

Another option is to use a 3rd party tool. The process you are describing is known as "data driven" publication. You can provide a recordset and one or more reports will be executed against each record in the recordset. So instead of changing the report you can provide a query , which will retrieve all possible records and then run the report in the normal way for each of the values returned by the query. You can check R-Tag Report Manager (www.r-tag.com). The only think I am not sure it can do is to combine all generated files at the end, because they will be related to different records. But this might be possible too, you need to ask the tech support. They have a free viewer , which is able to handle this scenario. Double check if the license is free because I noticed some recent changes in licensing.
0
 

Author Comment

by:fpkeegan
Comment Utility
I work for a large Corporation , this limits the use of any other software products.  It would take more than a year to get a new product in here to just test.  This place is really locked down.  We do not even have admin rights on our own PCs. And USBs are outlawed.  

The soultion needs to be a crystal reports solution.
0
 
LVL 18

Expert Comment

by:vasto
Comment Utility
The other option is to get the list of all items in the main report, put your subreports in the details section, group by item id ( or whatever unique field you have). if your query returns just one record the report will work as now. If the query returns multiple records  you will see result similar to resulls from data driven reports. You can use Group Header / Footer to print the data which is printed on report header / footer in your current report.
0
Why You Should Analyze Threat Actor TTPs

After years of analyzing threat actor behavior, it’s become clear that at any given time there are specific tactics, techniques, and procedures (TTPs) that are particularly prevalent. By analyzing and understanding these TTPs, you can dramatically enhance your security program.

 
LVL 22

Expert Comment

by:Ido Millet
Comment Utility
Why not simply group the report on whatever that parameter controls.  This would allow you to place the subreports in Group Footers instead of Report Footers.  When the user selects a regular value in that parameter, only one Group would be selected.  

When the user selects ALL, the record selection would bring in all Group values and you would get the desired result.
0
 

Author Comment

by:fpkeegan
Comment Utility
The data cannot go in to the detailed section. The report has a report footer section  that is not a sub report . The footer is for a cross tab report. The cross tab report must be in the footer section because cross tabs that are in sub reports will not expand horizontally.


I will try the group footer.
0
 

Author Comment

by:fpkeegan
Comment Utility
Getting closer.
There is  one group header , that contains the page header. It has the "Change Group options" , with the "Repeat group header on each page" checked. The data in the group header changes on each loop.
The details section is hidden,
There are 6 separate group footers , each one contains a separate sub report or a crosstab report.
The data in each section prints correctly. The problem is that the  group Page header only prints on the first page of each loop. Not on each page that makes up the group footer..
0
 

Accepted Solution

by:
fpkeegan earned 0 total points
Comment Utility
The group footer header problem is a known problem. This is the work around.

http://scn.sap.com/thread/2090303
0

Featured Post

Highfive Gives IT Their Time Back

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Crystal Reports: 5 Tests for Top Performance It is complete, your masterpiece report.  Not only does it meet your customer’s expectations, it blows them out the water, all they want is beautifully summarised and displayed in a myriad of ways. …
I hate sub reports and always consider them the last resort in any reporting solution.  The negative effect on performance and maintainability is just not worth the easy ride they give the report writer.  Nine times out of ten reporting requirements…
Access reports are powerful and flexible. Learn how to create a query and then a grouped report using the wizard. Modify the report design after the wizard is done to make it look better. There will be another video to explain how to put the final p…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

744 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

18 Experts available now in Live!

Get 1:1 Help Now