DBMS_RANDOM module

The DBMS_RANDOM module provides the capability to produce random numbers. It provides functions and procedures to seed a random number generator and then return random numbers or strings.

The schema for all procedures and functions in this module is SYSIBMADM.

The DBMS_RANDOM module includes the following built-in routines:

Table 1. Built-in routines available in the DBMS_RANDOM module
Routine name Description
SEED procedure The SEED procedure seeds the random number generator with a number.
SEED_STRING procedure The SEED_STRING procedure seeds the random number generator with a string.
INITIALIZE procedure The INITIALIZE procedure seeds the random number generator with a number.
TERMINATE procedure TERMINATE is a no-op procedure which provides no operation.
RANDOM function The RANDOM function returns a random number in the range of -231 and 231.
VALUE function The VALUE function returns a random number in a specified range.
STRING function The STRING function returns a random string.
NORMAL function The NORMAL function returns a random number in a standard normal distribution.

The DBMS_RANDOM module relies on the random number facilities of the host operating system. The random number facility of each host might vary in factors such as the number of potential distinct values and the quality of the randomness. For these reasons, the output of the functions and procedures in the DBMS_RANDOM module are not suitable as a source of randomness in a cryptographic system.