real()

Scalar. Converts a given string into a float.

Syntax

real ( string )

Parameters

string

A valid string must be a sequence of digits, optionally containing a decimal-point character. The input may also include an optional minus sign as the first character, or an optional exponent part, which itself consists of an 'e' or 'E' character followed by an optional sign and a sequence of digits.

Usage

Converts a given string into a float. The function takes a string as its argument, and the function returns a float. An invalid string causes the function to return NULL.

Example

real ('43.4745') returns 43.4745.