In Oracle Sql developer 11g, how do I generate a random integer and assign it to a variable? This is what I\'ve tried so far:
S_TB := SELECT dbms_random.value(1,
DECLARE l_check Integer:=1; BEGIN WHILE l_check < 5 LOOP l_check := DBMS_RANDOM.VALUE(1,10); DBMS_OUTPUT.PUT_LINE(l_check); END LOOP; END;
-- DBMS_RANDOM.VALUE Gives the random value within the range.