Calculating totals from formulas that represent different groups - crystal-reports

I have a Crystal Report that shows different groups(or departments) utilizing the groups in Crystal Reports. I then used some formulas to calculate Attached and Unattached assets in each group. Now I wish to show a total for the column of Attached and Unattached, what is the best and simplest way to do this?
Update
Okay I have been able to use a running total on #countattached that gets me close to what I need, the only problem is that it wants to add the last group total to the next group. The report is set up so the Employee (I.E. Jane Doe) and under that Employees name are Groups that, that Employee adds reports too such as Parks, Water, Streets , Etc. those Groups have a field across from them for Attached and Unattached with a total for both together at the end for each Group. I need a total for each Group under the column of attached and Unattached..
CrystalReport

Okay I finally figured it out if you have a series of columns that have sums for individual groups(parks,streets,water) under employees all you need to do to calculate the totals of those groups is right take the formula that has the sum for those groups, , such as (#countAttached). Then do a Running Total in the Running total dialog box, you can then set it to reset after each individual that those groups apply to then you have a those totals for that column. You just repeat this process for any other Columns you have.

Related

Add a Calculated Row For Custom Subtotaling

I'm trying to perform custom subtotaling on sales data to give a total for US and Non-US sales offices. My worksheet looks like the table labeled "current" and I am trying to make it look like the table labeled "desired result"
When I tried to group the sales centers as US and Non US the pill (dimension) was greyed out. After googling through a bunch of threads I found that grouping was not supported for secondary data sources. Is there anyway to do a manual calculation in the table calculations to add a row or do custom subtotaling?
Add a column for the country (assuming that you have the country in your data)
[see my example I had states and zip codes]
Then go to analysis > totals > check on show grand total and on add all subtotals
Visit Calculations totals - Grand total turn on for more information.

How to get individual group totals in report

I have a jasper report being made with iReport, which is basically a list of pages received the day prior. The report has total pages for the whole day and then individual totals for each group of page types.
The requirements state I need to display all the totals above the listed records and groups (ex. display in the title band). I created a variable for the total of all pages and that works but am having trouble getting each individual group total.
It should look like:
Total pages received: 50
Total GROUP_A: 20 Total GROUP_B: 30
When I try to use the variable set up for group totals, it only gives me the last used group, so it would say 30. I'm unsure how to create a variable to get the total for only a specific group.
I could include in my SQL result set the totals but was asked to do it within iReport.
If I understand the problem right you need to put a copy of the variable that you are using in the group and put it in your title band. the trick is on the object in the title band make sure you have set the evaluation time & evaluation group group or report depending on what you are truing to get a total of.

SSRS 2008 R2 - Group toggle aggregates

I'm working with a dataset where employee utilization is calculated as (Time Billed to X/Standard Billable hours). As such, to get the total billable percentage for an employee, I can just sum up the percentages billed to each client. However, I also want to be able to see the percentage of time billed by department.
I've currently got my data in a matrix with row groups Department-->Employee-->Client with 1 column group of "time sheet ending date". When I toggle the visibility of the client row group based on the employee row group, I get the correct totals at the client and the employee level. However, when I toggle the visibility of the employee row group based on the department row group, the department row group has the wrong totals. For example, if Department A has employee B with 90% utilization and employee C with 95% utilization, the toggled total at the department level is 185%....However, I am expecting to see 92.5%....any ideas????
You might just need to tweak the expression used to get the department total. I am unsure what expression exactly you used, but it should be of the form:
SUM(epmployeePercentageColumn)/COUNT(employeePercentageColumn)
obviously replace the "employeePercentageColumn" with whatever field or variable or expression that represents each of the employee percentages that come under the particular department.
If your current expression isn't in that form, try and tweak it.
Hope it Helps.

Crystal Reports - Total Count

looking to show an employee total on a report which has the following.
The report shows, by company divisions, count of employees to have had their annual assessment, I also wish to show total employee count per division so we would show
North Division - 50 employees had assessment out of 170 employees
East Division - 30 employees had assessment out of 50 employees
I cant seem to figure how to show the total count by division.
any pointers would be appreciated.
First of all; you need to group your data by Division.
You then need add a running total: Set it to count a a field displayed on each line (such as employee id). Then click in the "Evaluate" section - "Use a formula". Click the X-2 button to open the formula editor.
Your formula will be dependant on your data. You want it to output "True" for employees who have had their assement and false otherwise. [*]
Then in the "Reset" section, click "on change of group" and select your division group.
Now place your running total in the group footer of the division group.
[*] if this does not work, you will need to create a formula that outputs 1 or 0, on every line depending on whether the employee has had an assessment. Then create a sum on this formula to count the employees.
There are multiple methods of achieving what you want. Google "Crystal Reports Conditional Sum" for more answers.

Conditional group SUM in Crystal Reports

I've been doing some accounting reports and have been summing up my different currencies using a formula
IE
CanadianCommissionFormula
if {myData;1.CurrencyType} = "CDN" then
{myData;1.Commission}
else
0
CanadianCommissionSum
SUM({#CanadianCommissionFormula})
Then I'd just display the CanadianCommissionSum at the bottom of the report and things were great.
I've just come across the requirement to do this, but grouped by Sales Rep. I tried using my previous formula, but this sums for the whole report. Is there an easy way to sum like this, based on which group it's in?
You probably figured this out a year ago, but just in case, try this:
Change your CanadianCommissionSum formula to
SUM({#CanadianCommissionFormula},{SalesRep})
Put this formula in your SalesRep's Group Footer section.
This should now display properly.
Create a group based on the sales rep in the Crystal Report, and place the:
SUM({#CanadianCommissionFormula})
...in the footer of the group.
I would assume that rexem's suggestion should work but since you said it gives you a total all of the sales reps you could change the sum to running total. Before doing this I'd double check that you have your field in the correct footer section though.
To do the running total, group by Sales Rep, and then set up your running total to evaluate on every record and reset on the change of the group. Then you can put this running total in the group footer and it will show subtotals.
Hope this helps.