Print Page | Close Window

Need weird distinct count

Printed From: Crystal Reports Book
Category: Crystal Reports for Visual Studio 2005 and Newer
Forum Name: Report Design
Forum Discription: The best way to design a report and problems you have encountered
URL: http://www.crystalreportsbook.com/forum/forum_posts.asp?TID=460
Printed Date: 07 May 2024 at 5:05am


Topic: Need weird distinct count
Posted By: DIYer
Subject: Need weird distinct count
Date Posted: 04 Apr 2007 at 5:36am

I have to come up with a report each month with a daily count of system users in our call center (# varies a lot each month - very seasonal).  Here's the situation - there's nothing in the data which would consistently let me do a distinct count of user ID's by date, because not everyone does the same task each day.  However, everyone either either does Task A or Task B (or both), and the data for these tasks exists in two separate tables - Table A and Table B.  It's easy to do a report to show a distinct count of each, but how do I combine the groups (or whatever would work) to get a distinct count of every user name which is in Table A, B, or both?  I hope that makes sense to you!

 



-------------
Thanks for your help!



Replies:
Posted By: BrianBischof
Date Posted: 04 Apr 2007 at 9:42am
I would use a SQL Command object to do a UNION of the two tables so that they are combined into one table. Then do a distinct select from that resultset.


-------------
Please support the forum! Tell others by linking to it on your blog or website:<a href="http://www.crystalreportsbook.com/forum/">Crystal Reports Forum</a>



Print Page | Close Window