Radom records from a table

  • Thread starter Thread starter kotesh
  • Start date Start date
K

kotesh

hi,
can some body help me out in generating a random records from a table.
for example i have some questtionaire in my table which i want to pick
up random questions.
but the problem is, the questions have different levels like Basic,
intermediate and advanced. also groups in questions. please suggest me
how do i do this.
 
You want to build a query with the questionID as one field and a random
number as the second field (re-generated each time you run the query). They
you want to order the quey by the random number and pick the top x records.
If you want to make sure you get say 10 basic, 5 intermediate, and 2
advanced then you will need to add the level, and pick the top x records
from each group.

Take a look at in the help file for random numbers.

Ed Warren
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Back
Top