1, random number function: Dbms_random. RANDOM
1 SELECT ABS(MOD (Dbms_random. RANDOM, -)) fromDUAL;--generate a random number within 1002 SELECTTRUNC ( -+ the*Dbms_random.value) fromDual--generates a random number between 100~10003 SELECTDbms_random.value fromDual--generates a random number between 0~14 SELECTDbms_random.value (Ten, -) fromDual--generates a random number between 10~205 SELECTDbms_random.normal fromDual--The normal function returns a set of numbers that obey a normal distribution
SELECT from dual; -- Generate random string returns a random string of up to 60 characters in length. (not tested successfully)select dbms_random.string ('P', Dual; The first argument P means printable, that is, the string is made up of any printable character the second parameter represents the return string length selectfrom table order by Dbms_random.value; -- randomly fetching the URL of a record from a table
2.
Functions in the Oracle database