• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1255
  • Last Modified:

Crystal Reports 10 - How to Display Duplicate Records

Can any one help me.

I am running Crystal Reports 10 and wish to display any record that is duplicate. It is a single table at the moment.

This is an example....

ID  Name Age
1  Alan    18
2  Chris   19
3  Chris   19
4  Jane    20
5  Jack    18
6  Jack   18

I want to display

Chris 19
Jack 18

How is this done. I have heard of previous value etc but how is this done in formulas.

I am new as you may have noticed to Crystal Reports.


0
directred
Asked:
directred
1 Solution
 
mlmccCommented:
Try this

Group on the name field
In the group header add the fields to display
Suppress the group header using a formula
   Count({NameField},{NameField}) = 1

mlmcc
0
 
SpydergtCommented:
Or you can use a formula to create a more uniqque group incase he has jack 17 and jack 18.  Basically {field1}+{field2}+{field3} would be the formula.  Gorup by the formula.  And surpress based on the count like the previous poster mentioned.
0
 
directredAuthor Commented:
I tried the above but still getting problems.
Done the following
1..Made Name a group
2.Went into the Format Field of the group
3.Selected common tab
4.Selected Suppress if duplicate.
5. Put in the formula
count({NAME},{NAME}) > 1
6.Ticked and also unticked Supress if duplcate
7. OK that and ran again.

Still getting the wrong display.
I must be doing something really stupid. Sorry if I am.
0
Cloud Class® Course: Ruby Fundamentals

This course will introduce you to Ruby, as well as teach you about classes, methods, variables, data structures, loops, enumerable methods, and finishing touches.

 
directredAuthor Commented:
Added comment....

Example of display....

Alan
      18
Chris
     19
     19
Jane
     20
Jack
    18
    18

I want only Jack and Chris to be displayed with their numbers.

Hope this makes sense?
0
 
mlmccCommented:
The count statement needs to use your fields.


Are you using it in the SUPPRESS formula?

mlmcc
0
 
directredAuthor Commented:
I am using it in the SUPPRESS formula within the suppress to duplicate option.

Hope this makes sense?
0
 
mlmccCommented:
No use it in the SUPPRESS formula in the SECTION EXPERT

mlmcc
0
 
H0P5Commented:
A cross tab might be an easy way to do it.
You would then show each name only once, and you could display the max age against it.
0
 
directredAuthor Commented:
Thanks for your help. Once I put the formula in the correct area, it works a treat. Thanks again
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Cloud Class® Course: SQL Server Core 2016

This course will introduce you to SQL Server Core 2016, as well as teach you about SSMS, data tools, installation, server configuration, using Management Studio, and writing and executing queries.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now