INTELLIGENT WORK FORUMS
FOR COMPUTER PROFESSIONALS

Log In

Come Join Us!

Are you a
Computer / IT professional?
Join Tek-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Tek-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Jobs

Grant Total for a distinct count by group

Grant Total for a distinct count by group

(OP)
I have a report that shows sales and job count for YTD and sales and job count for current month.

I have a formula to show the job count for the month that the report was run but I can't figure out how to get a grand total of those numbers.


Report: Ran february

job count monthly sales ytd job count and ytd sales
ABC Customer 2 500.00 5 1,200.00
so january had 3 jobs at 700.00 but I only want the february job count to display and then I need a grand total of all customers job count
DEF Co 1 100.00 3 350.00

Grand Total 3 600.00 8 1,550.00

RE: Grant Total for a distinct count by group

You need to use a variable to capture values at point where subtotals are displayed and then display var in report footer

If a report wide total you need three formula

@Eval// place in group where subtotals are calculated
Whileprintingrecords;

Global numbervar ytdCount;
Global numbervar ytdsales;

ytdcount:= ytdcount + count(yourfield, yourgroupfield);
ytdsales:= ytdsales + sum(yourfield, yourgroupfield);

@DisplayCount // place in report footer
Whileprintingrecords;

Global numbervar ytdCount;

Repeat for ytd sales
Ian

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Tek-Tips Forums free from inappropriate posts.
The Tek-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Tek-Tips forums is a member-only feature.

Click Here to join Tek-Tips and talk with other members!

Resources

Close Box

Join Tek-Tips® Today!

Join your peers on the Internet's largest technical computer professional community.
It's easy to join and it's free.

Here's Why Members Love Tek-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close