Report Design
 Crystal Reports Forum : Crystal Reports 9 through 2022 : Report Design
Message Icon Topic: How to determine diversity counts Post Reply Post New Topic
Author Message
$$Dr
Newbie
Newbie


Joined: 18 Feb 2016
Online Status: Offline
Posts: 16
Quote $$Dr Replybullet Topic: How to determine diversity counts
    Posted: 14 Mar 2018 at 5:37am
Am trying to derive diversity counts on a new hire report. Race code is part of the report design by way of a formula that displays the code as a text description. Not sure of how to determine a count for each race code at both a group level sort and report total.
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 14 Mar 2018 at 6:46am
do you want a chart? a table? something else?

Example, drop a pie chart into the group header or footer for the group level you want to see
set the On Change of to the race text description formula field
set the show values as the distinct count of the employee id
Copy the chart and paste it into the report header or footer for the report totals
IP IP Logged
$$Dr
Newbie
Newbie


Joined: 18 Feb 2016
Online Status: Offline
Posts: 16
Quote $$Dr Replybullet Posted: 14 Mar 2018 at 7:14am
The request is for a simple count data point on the report.

IP IP Logged
$$Dr
Newbie
Newbie


Joined: 18 Feb 2016
Online Status: Offline
Posts: 16
Quote $$Dr Replybullet Posted: 14 Mar 2018 at 7:54am
This is the SQL for the report:

 SELECT "HQCO"."HQCo", "HQCO"."Name", "HRRM"."HRCo", "HRRM"."PRCo", "HRRM"."HRRef", "HRRM"."PREmp", "HRRM"."LastName", "HRRM"."FirstName", "HRRM"."MiddleName", "HRRM"."HireDate", "HRRM"."PRGroup", "HRRM"."PRDept", "HRRM"."PositionCode", "HRPC"."JobTitle", "HRRM"."ActiveYN", "HRRM"."Suffix", "HRRM"."Race", "HRRM"."Sex"
 FROM   ("Viewpoint"."dbo"."HRRM" "HRRM" INNER JOIN "Viewpoint"."dbo"."HQCO" "HQCO" ON "HRRM"."HRCo"="HQCO"."HQCo") LEFT OUTER JOIN "Viewpoint"."dbo"."HRPC" "HRPC" ON ("HRRM"."HRCo"="HRPC"."HRCo") AND ("HRRM"."PositionCode"="HRPC"."PositionCode")
 WHERE  ("HRRM"."HireDate">={ts '2018-03-01 00:00:00'} AND "HRRM"."HireDate"<{ts '2018-03-15 00:00:00'}) AND "HRRM"."HRCo"<>101 AND "HRRM"."ActiveYN"='Y'
 ORDER BY "HQCO"."HQCo", "HRRM"."HRCo", "HRRM"."PRCo", "HRRM"."HRRef"
IP IP Logged
DBlank
Moderator
Moderator


Joined: 19 Dec 2008
Online Status: Offline
Posts: 9053
Quote DBlank Replybullet Posted: 14 Mar 2018 at 10:16am
I don't understand what you are asking.
Maybe you could use crosstab instead but a 'simple count' is just inserting a summary as a count of a field and placing it a group or report header/footer. I don';t think that is what you are looking for. i think you want a grouped summary inside the group. If you don't want a graph then try a CrossTab.
IP IP Logged
Post Reply Post New Topic
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



This page was generated in 0.031 seconds.