Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Report Design
Message Icon Topic: Subreports - Main parameter w/ multiple values Post Reply Post New Topic
Author Message
Emmsna
Newbie
Newbie


Joined: 06 Apr 2010
Online Status: Offline
Posts: 2
Quote Emmsna Replybullet Topic: Subreports - Main parameter w/ multiple values
     Posted: 06 Apr 2010 at 11:12pm
Hi!
 
I have a report that has a subreport.
My main report has a parameter to allow the selection of multiple "locations".
My Subreport is set up to select the "locations" as per the main reports parameter, but it is only returning 1 location instead of all locations selected in the main report's parameter.
 
Any ideas?
 
Thanks!
IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4374
Quote lockwelle Replybullet Posted: 07 Apr 2010 at 3:18am
are the types of parameters the same?  What I mean be that is, depending on how the multiple locations are selected, the main report might be using an array, and I don't know if you can join a subreport to the main report using an array.
 
This could be your problem.  I don't use subreports too often, but from my limited experience, I can't think of how to join them just because CR doesn't really tell you that the main report is an array...perhaps you need to set the parameter in the subreport to 'Allow multiple values'....but I'm not sure.
 
HTH
IP IP Logged
Emmsna
Newbie
Newbie


Joined: 06 Apr 2010
Online Status: Offline
Posts: 2
Quote Emmsna Replybullet Posted: 07 Apr 2010 at 3:35pm
Thanks Lockwelle.
More Info:
The main report is very simple. Is is a "roster" report, so we have employees, the date, their start time, and their location. The main report has parameters to select the date and the locations for the rosters we want to see. The locations are strings, eg "Cafe", "Kitchen", "Bar" etc. The Main Report is Grouped by Employee. The Sub Report is in the Employee Group and it has to pick up the employee, the date, and the locations. But where I have selected for example "Cafe" and "Kitchen" in the main report, the sub report is only showing one location. So an employee that is rostered only to "Cafe" is fine, or just to "Kitchen" is fine, but where an employee is rostered to both "Cafe" and "Kitchen" it is onlying showing one of the locations.
The reason why I'm using the Sub Reports is to create a column for each date (Monday, Tuesday etc) so it kinda looks like a table.
 
What do ya think?
IP IP Logged
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum