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.

Calculation only updating when record saved

Featured Replies

  • Newbies

Hopefully I can explain this situation fully. I am building an invoice solution and am having problems getting some of my calculation fields to update without having to first save the main record.

Schema Summary

Main Tables:

- Transactions

- TransactionItems

These tables have the following relationship: Transactions::Id = TransactionItems::TransactionId

Each transaction item has a TaxCode, so I also have two instances of the TransactionItems table:

Tax1_TransactionItems

Tax2_TransactionItems

These tables instances are also related to the main Transactions table but only contain items that match either TaxCode 1 or TaxCode 2

In the Transaction tables I have the following calculation fields.

SubTotal = Sum(TransactionItems::ItemTotal)

Tax1SubTotal = Sum(Tax1_TransactionItems::ItemTotal)

Tax2SubTotal = Sum(Tax2_TransactionItems::ItemTotal)

In my layout I use a Portal to Show as well as add new TransactionItems.

PROBLEM:

When I am adding/editing TransactionItems only the SubTotal field updates itself immediately after changing the TransactionItems::ItemTotal field. Both Tax1SubTotal and Tax2SubTotal will not update themselves until I commit the Transactions record.

Can anyone suggest a better way of constructing my relationships or a trick to force Tax1SubTotal and Tax2SubTotal to auto update? I have tried adding a Script trigger which forces a RecordCommit when portal rows are being edited, but this is sloppy and doesn't work effectively.

Create an account or sign in to comment

Important Information

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

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.