Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Random numbers by equal group wise

user1758353Feb 3 2016 — edited Feb 17 2016

There are  1100 records in a table. I would like to divide the  1100 by equal groups and would like to apply random numbers(1-100 ) equally for each group. I am able to assign the random numbers to the records but not equally by group wise       CREATE table test_2 as     SELECT email, round(dbms_random.value(1,100)) RandomNumber   FROM test2 t     select count(*),randomnumber from test2   group by randomnumber       Can you please suggest Example : 1100 records by group wise means 11 sets and each 11 sets of records should be assigned randomnumbers (1-100) Thanks

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 16 2016
Added on Feb 3 2016
13 comments
986 views