You need to join the random to the query so that it appears as a column, then mysql can order it for you. Best done with the id, you multiple a column by 0 and add a random amount to it. This gives you a random number for each row, mysql orders it by that column.
My example uses
id col1 col2 category
0 Tom Raye edu
1 Joe Dell soc
2 Pat Kery soc
3 Wil Star soc
4 Ali Aman edu
5 Sue Scot rec
$sql =
select col1, col2, category, id*0+rand() as random from tbl, ORDER BY random DESC
should output something like
col1 col2 category random
Tom Raye edu 0.589
Joe Dell soc 0.348
Pat Kery soc 0.286
Wil Star soc 0.027
Ali Aman edu 0.015
You can never order by rand() alone
happy randoming
mike