Calculated Fields and Rollups Overview
Some numbers should never be typed in. A line total is quantity times price less discount; an invoice total is the sum of its lines. If a person can edit those figures, or they are only worked out in the browser, the system will eventually bill somebody the wrong amount.
Why the browser is not good enough
ActiveManage has long done arithmetic in a line-item builder as you type. That is useful for showing a running total, but it is display only. A value produced in the browser is a value the user can change before saving, nothing recalculates it if the row is edited later, and nothing can add it up across rows. An ERP cannot bill from a number like that.
Calculated fields close the gap. The arithmetic runs on the server every time the row is saved, using the values actually being stored.
The two kinds
- Formula — reads other columns on the same row. A line total from quantity, unit price and discount.
- Rollup — reads a child datastore and aggregates it. An invoice net total, being the sum of the net on each line.
They work together: a formula produces a value on each line, then a rollup totals it onto the header.
Where to find it
These live in a datastore called Calculated Fields, opened from All Datastores in the Architect Panel. One row per derived column, with an Enabled tick so a calculation can be suspended without being deleted.
How this relates to the rest of the ERP layer
Calculated fields are the lowest layer, and unlike the other modules they need no binding — they are configured directly against a datastore and its columns. Higher modules assume the numbers underneath them are already right: the ledger posts what a document says, and a document total is usually a rollup. Get this layer correct first.