Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Random data from the database table

Former Member
0 Likes
437

Hi

I need to obtain random data from the database table.

I have got a table which has got Questionid, Question, Option1, Option2, Option3, Option4, Answer as fields.

This table has got 100 questions I need to obtain 30 records from this table randomly and display that 30 records in new table say "A" with the same fields. Every time I need to obtain different records and put that in that table "A".

The size of this table can change now it is 100 but later it came be 150 or it can be 50 also.

Please provide with solution code.

Thanking You,

Swapnil

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
366

Hi

Use the Funcation Module : AQ_INT_RANDOM_NUMBERS.

For this pass Low,high and execute,this FM will genarate the number from u r specified range into table.

Regards,

Raghu.

1 REPLY 1
Read only

Former Member
0 Likes
367

Hi

Use the Funcation Module : AQ_INT_RANDOM_NUMBERS.

For this pass Low,high and execute,this FM will genarate the number from u r specified range into table.

Regards,

Raghu.