Jump to content
View in the app

A better way to browse. Learn more.

FMForums.com

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Grand Total Problem

Featured Replies

Hi--

I created a layout which contains a header, a trailing sub-summary, and a trailing Grand Summary. In the file, I have a series of items ordered by the client. Each item is assigned to a particular Category. The purpose of the layout is to show the client the Totals for each Category, and then a Grand Total. As well, the client needs the Totals for each Category to be Rounded. So I created the following fields:

Item Total: a calculation field which is the total for each item.

Total Amount: Summary = Total of Item Total

Total Amount Calc: Calculation = Round(GetSummary(Total Amount, Category), -2)

I Then created the trailing sub-summary when sorted by Category and placed both the Category and Total Amount Calc fields within the sub-summary part.

This successfully rounds out the Totals in each Category.

However, I have not been able to successfully create a Grand Total field which totals the amounts given by the Total Amount Calc field to be placed in the trailing Grand Summary part. Does anyone know of a way to do this?

Thank you!

Best Regards,

Jeffrey Ellis

------------------

--

Jeffrey Ellis

Groundlevel Software

[email protected]

Place your Total Amount field in the Grand Summary part. That field can do double-duty, showing sub-totals when in a sub-summary part and grand totals when in a grand summary part.

Chuck

  • Author

Hi, Chuck--

Yes, I tried that. Unfortunately, if you wre to look at another layout in list mode you would see:

Item Category Item Total Total Amount Calc

Filter Equipment 457.00 1400.00

Heater Equipment 300.00 1400.00

And so on. So the Total Amount Calc field, or a summary of that field would give you not the total that you see in preview mode, but the complete total of Total Amount Calc in ALL records...being much more than the actual amounts.

Best Regards,

Jeffrey

------------------

--

Jeffrey Ellis

Groundlevel Software

[email protected]

quote:

Originally posted by rlinsurf:

Total Amount: Summary = Total of Item Total

Total Amount Calc: Calculation = Round(GetSummary(Total Amount, Category), -2)

I Then created the trailing sub-summary when sorted by Category and placed both the Category and Total Amount Calc fields within the sub-summary part.

This successfully rounds out the Totals in each Category.

However, I have not been able to successfully create a Grand Total field which totals the amounts given by the Total Amount Calc field to be placed in the trailing Grand Summary

Your "Total Amount Calc" field will NEVER give you a Grand Summary. The GetSummary function should really be called GetSubSummary because it requires a break field as a parameter and that explicitly prevent it from calcing to a grand summary.

Use normal summary fields in your SubSummary and Grand Summary parts. Save the GetSummary calculations for use in other parts, or when you are not displaying the summary parts. This is what the function was designed for.

------------------

=-=-=-=-=-=-=-=-=-=-=-=-=

Kurt Knippel

Consultant

Database Resources

mailto:[email protected]

http://www.database-resources.com

=-=-=-=-=-=-=-=-=-=-=-=-=

  • Author

Hi, All--

I just wanted to thank you for all your fine suggestions. I also wanted to pass on thsi very simple solution sent by Paul haskell which solves this problem beautifully:

<<All you need, if I understand your problem, is the Total Amount field. Place

the field in both the sub-summary and grand total part. Sort your database

by category and print or preview.

You can round the numbers with number formatting in the layout, or round the

calculation for item total (preferably the latter).

Bye.

-=-=-=-=-=-=-=-

Paul Haskell

Ram Design

-=-=-=-=-=-=-=->>

------------------

--

Jeffrey Ellis

Groundlevel Software

[email protected]

  • Author

Sorry, I forgot to say, I used the first suggestion of simply formatting the Total Amount Summary Field, using "-2" under Fixed number of decimal places for both the sub-summary part and the trailing grand summary. This solved the problem.

------------------

--

Jeffrey Ellis

Groundlevel Software

[email protected]

You need a second Total Amount field just for the Grand Summary part. The calculation for this field would be:

Total Amount Calc: Calculation = Round(GetSummary(Total Amount, Total Amount), -2)

The Total Amount field replaces the break field to give you the GetSummary result over the entire found set. -bd

  • Author

Thanks, bd!

Jeffrey

------------------

--

Jeffrey Ellis

Groundlevel Software

[email protected]

Create an account or sign in to comment

Important Information

By using this site, you agree to our Terms of Use.

Account

Navigation

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.