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!

Sub-Report placement/linking issue

Status
Not open for further replies.

jack91

Technical User
Apr 13, 2009
185
US
Hi,

I am using Crystal Version 10.

I have one main Report with Page 1 having a cross-tab as well as 2 pie charts. The rest of the sections in this main report are all suppressed.

Now I have 3 sub-report which are based off of the pie charts. Which each section of the pie chart representing each sub-report.
Each of the 3 sub-reports have a chart in their report header, has a page header as well as relevant detail section.

Question is:
1)Where do i place the 3 sub-reports? Report header or page header of the main report?
2)I did try placing these 3 sub-reports in the page header and alternatively placing them in report headers.
I have tried the linking also ------.When i click on the pie section of the chart in the main report it ** shows me the relevant section of the sub-report ** BUT i see only the details of the sub-report not the chart in the sub-report.

How do i see the chart in the sub-report as well?

Thanks
Jk
 
I have put the 3 sub-reports one in each group header.

GH 2 uses a warranty expired formula:

if isnull({computer warranty.end_date})
then
"comp With NO Warranty INFO"
else if {computer warranty.end_date} <= CurrentDate then
"comp Out Of Warranty"
else
"comp Under Warranty"

so
GH 2a:comp Under Warranty
GH 2b:comp Out Of Warranty
Gh 2c:comp With NO Warranty INFO

If i use my clickable pie chart from the main report it takes me to the relevant details , but i need to show clickable bar charts from the sub-reports.

I hope I am being clear, if not I can explain again

thanks
Jk


 
Are you sure you are seeing the details of the subreports and not the Details of the main report.

How have you linked the subreports sofar?

I am guessing you have them linked by your warranty expired formula.

Ian
 
u are right on:

"--I am guessing you have them linked by your warranty expired formula."

What do i link on?

Also,

When i click on the pie chart for comp under warranty - I want to see the sub-report on GHa.
Ditto for the other two also

Jk
 
I have never linked a subreport to a pie chart dreill down and I am not sure you can do this.

Why are you using subreports?

With a pie chart linked to group you can have another chart in that group header, there will be no need to split header as new chart will run for each group.

Under Warranty
Out Of Warranty
NO Warranty INFO

Ian
 
Below is the breakdown of the report;

Tier1:

Computer are categorized into Critical and Non-Critical

Tier 2:

Each of the above (critical and non-critical) is further broken down into a pie chart having the 3 sections:
(using formula)
(
if isnull({comp.warranty_end_date})
then
"compWith NO Warranty INFO"
else if {comp.warranty_end_date} <= CurrentDate then
"comp Out Of Warranty"
else
"comp Under Warranty"
)


Critical computers:
1) Pie section 1: computers under warranty
2) Pie section 2: Computers out of warranty
3) Pie section 3: computers with no warranty info.

Non-Critical computers:
same breakdown 1-3 as above.

Tier 3:

Computers under warranty is broken down to a * Bar char using the formula: (basically how many computers which currently have warranty will be expiring in the future)

formula used:

if {comp.warranty_end_date} >= currentdate AND {comp.warranty_end_date} <= currentdate+30 then
"Less than 30 days"
else if{comp.warranty_end_date} > currentdate+30 and {comp.warranty_end_date}<= currentdate +60 then
"Between 30 - 60 days"
else if{comp.warranty_end_date} > currentdate+60 and {comp.warranty_end_date}<= currentdate +90 then
"Between 60 - 90 days"
else if{comp.warranty_end_date} > currentdate+90 and{comp.warranty_end_date}<= currentdate +365 then
"Between 90 days and 1 year"
else if{comp.warranty_end_date} > currentdate+365 and {comp.warranty_end_date}}<= currentdate +730 then
"Between 1 - 2 years"
else if{comp.warranty_end_date} > currentdate+730 then
"greater than 2 years"

For computers that have warranty expired (we want to find out when they expired in the past)
Formula used for this:

if {comp.warranty_end_date} < currentdate AND {comp.warranty_end_date} >= currentdate-30 then
"Expired within the last 30 days"
else if{comp.warranty_end_date} < currentdate-30 and {v_asset1.warranty_end} >= currentdate -60 then
"Expired Between 30 - 60 days"
else if{v_asset1.warranty_end} < currentdate-60 and {comp.warranty_end_date} >= currentdate -90 then
"Expired Between 60 - 90 days"
else if{comp.warranty_end_date} < currentdate-90 and{comp.warranty_end_date} >= currentdate -365 then
"Expired Between 90 days and 1 year"
else if{comp.warranty_end_date} < currentdate-365 and {comp.warranty_end_date} >= currentdate -730 then
"Expired Between 1 - 2 years"
else if{comp.warranty_end_date} < currentdate-730 then
"Expired greater than 2 years ago"

I have already created 3 individual reports:
computers with warranty
computers without warranty
computers with no warranty info

I now need a 4th report which encompassess all of the above 3 reports.

With the Tier 2 chart being clickable --> bar chart clickable --> details

any advise is appreciated

Thanks
Jk




 
Sounds like you want different data to be displayed for each
computer category.

computers with warranty
computers without warranty
computers with no warranty info

You can do this by splitiing group header into 3 sections and then conditionally suppressing based on group name.

eg in section expert
GH2a is suppressed when <> computers with warranty
You can then put a chart in there with specific headers and chart for the data you want.

YOu can also use Drilldowngrouplevel (crystal function) to do further suppression if required. Just create a formula with that function and place in drill down groups and you will see it returns a number depending on how far you have drilled.

What you are doing is very complicated so good luck.

Ian

 
If i want computers with warranty I will need to suppress the other two.

But these are not columns but formula created by me:
(
if isnull({comp.warranty_end_date})
then
"compWith NO Warranty INFO"
else if {comp.warranty_end_date} <= CurrentDate then
"comp Out Of Warranty"
else
"comp Under Warranty"
)

I will try to suppress two criteria and check.

The report seems easy on the outside but seems tricky when trying to actually do it.
If i don't get this report done soon by job might be on the line :-(

TIA
Jk
 
If you want the section to show only

"comp Under Warranty"


then in section expert suppress just add

@Yourformula <> "comp Under Warranty"

Repeat for others.

Ian
 
Ian Waterman:

Regarding what you said earlier:

"----You can then put a chart in there with specific headers and chart for the data you want"

computers with warranty needs to be paired with Future warranty expiration formaul

Computers that have warranty expired needs to be paired with Old warranty expiration formula

and then there is computers with no warranty info.


Since these also need to clickable to finally be able to show the details when a user clicks on the bar charts, I believe to achieve this I need to make these 3 combinations groups.

When I try to do this I dont quite get the desired combinations in the place chart (in criticality). "on change of" and "show"

I suppose if the requirement was not clickable for the Tier 2 chart it would have been easier.

please advise
Regards,
jk
 
YOu can create another formula group which links those categories together.

@category

if {@yourformula} = 'x' or {@yourformula} = 'y' then 'cat1' else
if {@yourformula} = 'a' or {@yourformula} = 'b' then 'cat2' else
etc

To drill down your chart would have to first show these categories. In the header for this new group you can have a chart for the two sub categories you want to show.

Ian
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top