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!

Excluded Criteria in Subreport Prints as Blank Fields in Main Report

Status
Not open for further replies.
Sep 11, 2008
25
US
We use Crystal 11 and a Remedy database, which does not allow table linking. Therefore, we must use subreports to print data from different tables.

I have a main report that uses the Vendor table to print Vendor Ticket#, Date Reported, and Date Resolved.

I have a subreport that is linked to Incident# and prints Agency and Department from the HelpDesk table.

I only want to display Voice data, which resides in the HelpDesk table. My subreport criteria is:

{HPD_Help_Desk.Incident Number} = {?Pm-NCC_HPD_VendorTicket.Incident ID} and
{HPD_Help_Desk.Product Categorization Tier 2} like "Voice*"

My problem is: All vendor tickets display, but the ones not like "Voice*" show the data from the Vendor table and empty fields from the HelpDesk table.

I'm not sure if this is a clear explanation.

In the main report, I have set the subreport to "Suppress Blank Subreport" but that does not prevent the non-voice data from displaying in the main report.

Thanks for your help,

Old Gray Mare
 
You have to restrict the Vendor table as well to display only "voice" tickets like you did in the HelpDesk table select expert.


If there is no way you can restrict in Vendor report,then try doing the other way,
Use vendor report as the subreport.
 
I can't tell what section you have placed the subreport in. Let's assume you have a group on incident# in the main report. Then you would place the subreport in GH_a, format it to "suppress blank subreport", and format GH_a to "underlay following sections" and to "suppress blank section". Then in the subreport, create a shared variable to be placed in the subreport footer:

whileprintingrecords;
shared stringvar incidID := {NCC_HPD_VendorTicket.Incident ID};

Then in the main report->section expert->main report sections->suppress->x+2 and enter:

whileprintingrecords;
shared stringvar incidID;
incidID = ""

Create a reset formula to be placed in the report header and in the incident group footer of the main report:

whileprintingrecords;
shared stringvar incidID := "";

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top