DBMS RANDOM

From Oracle FAQ
Jump to: navigation, search

DBMS_RANDOM can be used to generate random numbers.

Examples[edit]

SELECT mod(trunc(dbms_random.random/10000000)) FROM dual;
BEGIN
  dbms_random.initialize(123);
  dbms_output.put_line( dbms_random.random );
  dbms_random.terminate;
END;
/