Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Combining 2 reports into one

Status
Not open for further replies.

kcoleman26

Technical User
Oct 26, 2007
66
US
CR2008

We have a user that is trying to combine two reports into one report. The reports are almost exactly the same with the exception of two fields. Both reports work great independentaly but they now want them to be one report based on the parameters that are selected.

The issue I have is weather I combine them or run them each as a subreport I still have to choose All parameters for both reports. The user doesn't want the confusion of irrelevant parameters.

Idealy what they want is to have one filter. {Project Type}<All Projects> or <Cancelled Projects> when <All Projects> is selected they have the option to filter it again by {Project Size} <All>, <Big>, <Med>, & <Small> or if they select <Cancelled Projects> they have the option to filter it again by {Project CXL Status} <All>, <Penalty>, & <No Penalty> the additional filter for each scenerio isn't the same field.
So in my inital filters it is making me select both {Project Size} & {Project CXL Status} but depending on the {Project Type} that is selected one of those filters is irrelevant.

I can't seem to find a solution to satisfy the need of the user. Any help would be appreicated.

Thanks
KC
 
Try this:

1. Create a command in the main report that will be used for the parameters. It will look something like this (SQL Server syntax):

Select 'All Projects' as ProjectType, 'All' as value
UNION
Select 'All Projects as ProjectType, 'Big' as value
UNION
...<one 'All Projects' record for each size value>...
UNION
Select 'Cancelled Projects' as ProjectType, 'All' as value
UNION
Select 'Cancelled Projects' as ProjectType, 'Penalty' as value
UNION
...<one 'Cancelled Projects' record for each status value>...

2. DO NOT join this query to anything else! If you have other tables in the main report, Crystal will complain that this is "generally not supported", but it will work in this case.

3. Create a Cascading Dynamic Parameter that has ProjectType as the first part and Value as the second. Label this second parameter as "Size/CXL Status". This will filter the values for the second parameter based on what is selected in the first.

4. Add the reports as subreports to the main report. Remove the size or status parameter from each subreport.

5. Link from the second parameter to each of the subreports, using this parameter in the main report in place of the parameter you've deleted from the subreport.

Save the report and you should be ready to go!

-Dell

DecisionFirst Technologies - Seven-time SAP BusinessObjects Solution Partner of the Year
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top