Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Report Design
Message Icon Topic: Remove Duplicate Records Post Reply Post New Topic
Author Message
joncolipapa
Newbie
Newbie
Avatar

Joined: 20 Dec 2009
Location: Philippines
Online Status: Offline
Posts: 1
Quote joncolipapa Replybullet Topic: Remove Duplicate Records
     Posted: 20 Dec 2009 at 11:18pm
Hello,

I have a simple query with results I want to display in CR2008. The query is able to display all the data I want but when I run the report, it produces duplicates according to the number of results. The query draws results from 2 tables - a header and detail table. When a header has 4 details, you naturally get 4 rows when you run a query that joins these tables. There's no problem with the query. But when I run the report, I noticed that data in the detail table is repeated according to the number of resulting rows. For example, if I have 3 resulting rows from my query, the report shows the 3 rows 3 times also... and for 2 resulting rows, the report shows the 2 rows 2 times also...

I need help. I'm a newbie and I've been trying to figure this out for 2 days now... I need to know how to remove these duplicate rows...
jon
IP IP Logged
lockwelle
Moderator
Moderator


Joined: 21 Dec 2007
Online Status: Offline
Posts: 4374
Quote lockwelle Replybullet Posted: 21 Dec 2009 at 6:15am
how many rows does the detail table have?  if you have 4 header and 4 detail, then they will match 16 ways. 
 
next, how are you getting the data? Using a stored proc/view?  Joining to the tables directly in CR?
 
if joining, try to limit the number of columns and then click Database/Select Distinct Records.  See if that helps.  Selecting distinct will cut down on the number of rows, but it may not completely solve the problems, because if too many columns are different (that you are using) then duplication will persist.
 
HTH
IP IP Logged
Printable version Printable version

Forum Jump
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot delete your posts in this forum
You cannot edit your posts in this forum
You cannot create polls in this forum
You cannot vote in polls in this forum