Quantcast
Channel: SCN : Unanswered Discussions - SAP Crystal Reports
Viewing all articles
Browse latest Browse all 4814

Crystal report returning duplicate rows - Linking issue?

$
0
0

Hello,

 

I know this is a commonly brought up issue - that duplicate rows are returned in Crystal reports for various reasons.  In a lot of instances, where it's only a single row of data per case that I'm looking for, I'll move them to their own group.  But that solution doesn't work here.

 

The tables and links used in the simple report I have are illustrated in the attached "Report Database Expert Links.jpg" file, and the conditions and report fields required as as follows:

 

Select Expert conditions:

 

{CLAIM_PERIODS.CPE_START_DATE} < Today and

{CLAIM_PERIODS.CPE_END_DATE} > Today and

{CLAIM_ROLES.CRO_START_DATE} < Today and

IsNull({CLAIM_ROLES.CRO_END_DATE})

 

Report Design fields (in Details section):

 

CLAIMS.CLA_REFNO, CLAIM_ROLES.CRT_CODE, PARTIES.PAR_PER_FORENAME, PARTIES.PAR_PER_SURNAME

 

 

So what this report is to do:

 

It looks for benefit claims which are live (have a CLAIM_PERIODS.CPE_START_DATE prior to today, and CLAIM_PERIODS.CPE_END_DATE after today), and for these claims gives a breakdown of all people in the household (everyone associated with that claim, where CLAIM_ROLES.START DATE is prior to today, and end date is null - to pick out those who are currently active in the household).

 

This works fine otherwise, but the issue is that each live claim can have either one or two rows present in CLAIM_PARTS and CLAIM_PERIODS (so could satisfy my first two conditions twice).  For claims with only a single claim part active, I get each household member listed once.  But when they have two claim parts active, I get eveyone listed twice.

 

Is there a way - either in how I'm linking the tables up, or how I'm arranging the report design, that I can have every household member only appear once no matter how many related rows there are in CLAIM_PARTS and CLAIM_PERIODS?

 

Many thanks in advance,

 

Sami

 

P.S. I don't seem to be allowed to attache image files to my post, but have embedded the content instead:

Report Database Expert Links.jpg


Viewing all articles
Browse latest Browse all 4814

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>