2

I am working on a report that uses multiple sub-reports. I have two parameters: t_driver_pk and BatchID for the report. I have been able to display the data for each driver on a new page in the subreport using page break and repeat header options (all the subreports have been grouped by t_driver_pk). But, then when I go to main report and run it selecting multiple drivers on t_driver_pk parameter. I am getting a single report that combines the data for all those driver. Essentially, I would like to have it displayed as following:

Parameters: **t_driver_pk**: 5000,4500 BatchID:610

FirstDriver

Subreport1

Subreport2

Subreport3

Subreport4

Second Driver

Subreport1

Subreport2

Subreport3

Subreport4

Any help would be greatly appreciated. Thanks in advance!

FutbolFan
  • 13,235
  • 3
  • 23
  • 35
  • What is your problem exactly? And what have you tried to fix the problem? It may be just me, but I'm having a hard time understanding the question. Some additional formatting on the text, example "code", and added details on the report structure(s) may help. – Jeroen Nov 13 '12 at 20:22
  • Thank you for your response. I am having problem trying to display the results for each driver that I select in the parameter to display on a different page in the main report. In other words, I would like to have Driver A and the subreports and then the next page begins with Driver B and the subreports. My aim is to build a main report where users can select multiple drivers and get report for each driver.I hope that makes sense! – FutbolFan Nov 13 '12 at 21:14
  • Note that you can (and are even encouraged to) edit your question to add details and clarifications. – Jeroen Nov 14 '12 at 07:29

1 Answers1

1

Have you tried adding a Dataset to the report that is driven by the selected t_driver_pk values (i.e. if 5000 and 4500 are selected in the parameter then the new dataset returns the same values).

You should be able to use this dataset with a List data region, which you can insert your subreports into and then pass the current value of t_driver_pk from the new dataset to the subreports. That should repeat them for each value of t_driver_pk.

Nathan Griffiths
  • 12,277
  • 2
  • 34
  • 51
  • Thanks Nathan for your answer. I tried adding a new dataset driven by the selected parameter values and added the subreports in the list data region, but it didn't seem to work. I am suspicious if the structure of my report is not built well. – FutbolFan Nov 14 '12 at 14:42
  • Actually, we figured it out. All I had to do was to add Distinct in my query. And, just like you said add the subreports in the list data region and it worked like a charm! Thanks Nathan. – FutbolFan Nov 14 '12 at 20:21