Create a new numeric column in the table, and fill it with random numbers, then query the table ordering it by the random number field:<BR><BR><%<BR>strSQL = "SELECT * FROM Tbl Order By RndFld"<BR>%>
ok, this takes me to a new question though...how can I create a new column each time I need to order the records and fill the fields with random unique values?<BR>I know how to create and delete a temporary column with sql...but I am unsure on how to fill all the fields with a (unique...necessary?) random number<BR><BR>thanks for helping<BR>
I'm not sure of the complete answer, but basically you just create the column once on the table, maybe access can automatically add a random number, If not just do an update query using the RND() function to populate the data. When you insert a record be sure to put a random number in it.
I understand...however there may be the problem that the rnd() generates doubles. Btw I am now using a different way. I used the getrows() function to convert the recordset in an array. I then sort the array randomly. <BR><BR>Thanks for the help anyway and sorry if I'm a bit late replying<BR>