Unless a specific type of result is required, such as text, option or duration, a basic calculation is the best calculation type to use when referencing individual fields within the current form. If it is necessary to perform a calculation on a table, one of the table calculation type fields should be used. To reference historical data, historical calculations can be used. For referencing data outside of the form (that is, from another event form or a profile form), linked calculations must be used. For most purposes, however, the basic calculation is frequently used.

EXAMPLE: WRITING A BASIC CALCULATION

As a simple example using the basic calculation field type, if you wanted to convert Height to centimetres from metres and then add this to the Weight, you could write the equation used here.

(Height * 100) + Weight

It is important to note that when referencing a field within a calculation, it is case sensitive (and space sensitive).

EXAMPLE: IF STATEMENTS

A common calculation used in Smartabase is an If statement. This allows us to return different values based upon specific conditions that should be met. This follows the standard notation for if/else notation. For example:

If(Logical Test, Value If True, Value If False)

As an example, if you wanted to perform a weighting calculation that multiplied an athlete’s workload by 10 when the Session Type was Match, but just return the unweighted Workload otherwise we could write the following equation:

If(Session Type = “Match”, Workload * 10, Workload)