Jarvis Posted February 20, 2006 Posted February 20, 2006 I have a database with the two following fields: WORKERS - HOURS. Typical values for each field might be as follows: WORKER HRS Betty 5 Billy 6 Skippy 2 Betty 1 Billy 2 Bob 5 Betty 5 Billy 6 Is there a way to find all occurrences of unique names and then total the values per unique name? I would like the end result to look like this: Betty 11 Billy 14 Skippy 2 Bob 5 I can figure out how to subtotal by field group, but it escapes me how to do this by individual field value. Any ideas? Thanks, Jarvis
Ender Posted March 1, 2006 Posted March 1, 2006 This is exactly what Sub-Summary parts are for. Create a columnar report layout, and add a Sub-Summary by Worker part. On that part insert the Worker Name and a summary Total of Hours field. You may remove the Body part from the layout so only the summaries show. Remember: Sub-Summary parts only show up in Preview Mode or on the printouts, and only after you sort the records by the fields used in the Sub-Summary parts. Usually it's best to create a script that simplifies the sorting, switching layouts, and preview/printing when making this of report.
davepain Posted March 1, 2006 Posted March 1, 2006 Hi, I am doing something simular but i also need a summary total (number) of how many unique staff they have i.e the result for the example above would be 4
Ender Posted March 1, 2006 Posted March 1, 2006 That's a little different. If I recall correctly, you'd need to do it with additional fields like these: Count of RecordID (summary) = Count of RecordID Fractional Count by Worker (calculation, number result) = 1/getsummary(Count of RecordID; Worker Name) Count of Workers (summary) = Total of Fractional Count by Worker When sorted by Worker Name, the Count of Workers should show the correct total.
Recommended Posts
This topic is 6842 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now