Apply

How to Convert a Value to a Single Floating Point (REAL)

Using Advanced Expression Piping within your forms you can create mathematical formulas in order to calculate a value. Using a REAL expression, results are displayed as a Single Floating Point (1.0, 2.5, 3.1, etc.) which can be ideal for reporting and display purposes. This article describes this expression further by providing use cases and rules for proper formatting.

The REAL function allows the expression to convert a set of values into an floating point or real value for either a single value or a list of values from a number of given fields. The difference between REAL and REALTWO is that REALTWO returns the value with two decimal places (1.00) whereas REAL converts the value to a single decimal place (1.0).

Additionally, If you are looking to have more than two decimal places within your response, you will need to use PRECISION instead.

The setup and formatting of the REAL expression is imperative in preventing an error message from appearing on your form where the result of your expression would normally appear. The first line of the REAL expression should be set up as follows:

• Each expression is always contained within a pair of double "curly" brackets {{  }}
• There should be a space between the first instance of REAL and the last bracket
• Variables you are using are case sensitive
• Always close the REAL operation with brackets ( )

What's different about REAL over some of the other functions is that REAL can be used in conjunction with other functions. For example, using the AVG Function, if we want to calculate the average of 3 values, should that value return a floating point, REAL can be used to ensure the value displays up to a single decimal point.