SAP Knowledge Base Article - Public

1765145 - Incorrect subreport opens, when drilling down on a subreport in Crystal Reports

Symptom

  • Incorrect subreport.
  • In InfoView, when drilling-down on a subreport, it open the wrong subreport.
  • In Crystal Reports, when drilling-down on a subreport, it open the incorrect subreport.

Environment

  • Crystal Reports 2008
  • Crystal Reports 2011
  • BusinessObjects Enterprise XI 3.1
  • SAP BusinessObjects Enterprise XI 4.0

Reproducing the Issue

  1. In Crystal Reports, create a report off any data source.
  2. Create a group, and insert a subreport with no data source connection in the Group Header section.
  3. Conditionally suppress the subreport to only display when the group equal to a certain value.
  4. Repeat step 2 and 3, and insert each new subreport on top of the next one. ( The subreports will be stack on top of each other )
  5. When viewing the report, if we click on the subreport to drill-down, it open a new tab, and displays the incorrect subreport.

For example: If we have 3 subreport, overlayed on top of each other in the Group Header in the following order:

  • Subreport A
  • Subreport B
  • Subreport C

Each subreport being conditionally suppressed to display the subreport A, when the group displays A, and the subreport B, when the group displays B,... When viewing the report and clicking on the Subreport B to drill-down, it actually opens the Subreport A on a different tab, when the expectation is to open the subreport B.

 

Cause

  • This situation occurs because the objects, subreports, are stack on top of each other.
  • When viewing the report, you see one subreport, but the suppressed subreport still exist, therefore when attempting to drill-down on what appears to be the subreport B, the user actually click on the subreport A object, which then open what appears to be the wrong subreport. 

Resolution

  • To ensure to drill-down on the expected subreport, insert one subreport per section, and conditionally suppress the section.
  • In this way, the subreports are not stacked on top of each other, and when the section is displayed, it only displays one subreport.
  • Below are the general steps on how to apply this solution:
    1. In the section the stacked subreport are located, create a number of sub-sections equal to the number of stacked subreports.
    2. Move each subreport in it's own sub-section.
    3. Conditionally suppress each sub-section to display the appropriate subreport.
    4. Now, when viewing the report, it only displays one subreport, and when clicking on the subreport, it will open the expected subreport under a new tab.

Keywords

CR, Sub , KBA , BI-RA-CR , Crystal Reports designer or Business View Manager , Problem

Product

Crystal Reports 2008 V0 ; Crystal Reports 2008 V1 ; SAP Crystal Reports 2001 V1 ; SAP Crystal Reports 2011 ; SAP Crystal Reports 2011, feature pack 03