Technical Questions
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Technical Questions
Message Icon Topic: Help with DistinctCount Post Reply Post New Topic
Author Message
jonberardi
Newbie
Newbie


Joined: 24 Jun 2008
Location: United States
Online Status: Offline
Posts: 6
Quote jonberardi Replybullet Topic: Help with DistinctCount
     Posted: 02 Nov 2009 at 10:43am
I am a novice crystal reports user struggling with what must be a common obstacle. Hopefully I can articulate this well enough to make sense. Any help is appreciated:
 
I have a report that displays a list of users and the courses they have completed. Some users have completed a course multiple times. To eliminate these records, I am using a distinct count to only count each course title once per user:
 
DistinctCount (CourseTitle, Username)

 These records are then grouped by manager, where I would like to summarize the DistinctCount for all of the individual users. This count should maintain the distinct course title count per user, but allow a single course to be counted for each user it is evaluating. How can I create a summary by manager?

Thank you.

Jon



Edited by jonberardi - 02 Nov 2009 at 10:44am
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 02 Nov 2009 at 12:10pm

Likely you can use a Running Total or a Variable formula here but you can also try using a fomula field to concantenate 2 uniqe fields togther then distinct count that.

table.Username + '-' + table.Coursetitle
 
DistinctCount{formula,managerfield)


Edited by DBlank - 02 Nov 2009 at 12:52pm
IP IP Logged
jonberardi
Newbie
Newbie


Joined: 24 Jun 2008
Location: United States
Online Status: Offline
Posts: 6
Quote jonberardi Replybullet Posted: 02 Nov 2009 at 1:19pm
Thank you, DBlank - your suggestion works perfectly!

Jon
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