random function

The rand function returns a positive pseudo-random number. The resultant value can be greater than or equal to zero and less than one.

Syntax:

double rand()

Semantics:

Example 1 - random function

SELECT rand() AS RANDOM from Archery WHERE sim=1

Output:

+-----------+-------------------+
| RANDOM    | 0.891655403699787 |
+-----------+-------------------+