The RAND function returns a floating point value between 0 and 1.
The data type of the result is double-precision floating point. If the argument can be null, the result can be null; if the argument is null, the result is the null value.
A specific seed value will produce the same sequence of random numbers for a specific instance of a RAND function in a query each time the query is executed. If a seed value is not specified, a different sequence of random numbers is produced each time the query is executed.
RAND is a non-deterministic function.
SELECT RAND(:HRAND) FROM SYSIBM.SYSDUMMY1Returns a random floating-point number between 0 and 1, such as the approximate value .0121398.
SELECT RAND(:HRAND) * 10 FROM SYSIBM.SYSDUMMY1
(C) Copyright IBM Corporation 1992, 2006. All Rights Reserved.