Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chris Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using a Sum in Another Function

Status
Not open for further replies.

socialresearch

Technical User
Apr 29, 2003
2
US
I am new to Crystal Reports.

I would like to sum points for each individual within a class and then report statistics (PopulationStdDev, NthSmallest, NthLargest, etc.) for this sum for each class.

The data are basically:
Year ID Points Class
2002 101 20 1
2002 101 15 1
2002 102 17 1
2002 102 18 1
2002 102 30 1
2002 107 33 1
2002 111 20 2
2002 111 27 2
2002 111 19 2
2002 114 11 2
2002 114 23 2
2003 101 40 1
etc.

I want to first sum up the points for each person in a class and then report the statistics for this sum by class. For example, for class #1 I want to sum up the total points for ID 101, 102, and 107 (e.g., to 35, 65, and 33) and then report the NthLargest for any person in the class (e.g., 65) and the standard deviation for the class (standard deviation of 35, 65, 33).

Can I do this in Crystal Reports?
How would I do this?
Would I need to specify two passes through the data, first to generate the sums and a second for the statistics?
Can I nest a Sum function within the PopulationStdDev?

Any suggestions?
 
Unless someone proves otherwise, I believe the Standard Deviation options only work on at the detail line level. This is not what you want (Hey what do I know, I left school early!)

But, a workaround would be to get the report to list the values you want and to export this to Excel or CSV. Produce a report against this extract using the built in functions.

Someone else may have a better solution though....

Steve Phillips, Crystal Consultant
 
Steve,

Thanks for explaining why Crystal Reports might not produce the right standard deviations and for suggesting I use Excel. Excel worked well.


 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top