Page 1 of 1

MySQL ORDER BY RANDOM... How?

Posted: Wed Mar 08, 2006 5:22 pm
by JellyFish
I'm trying to select data from the database and I'd like to order it by random. How must I do this?

Thanks and all help is appreciated.

Posted: Wed Mar 08, 2006 5:26 pm
by wtf
select * from table order by rand()

http://www.greggdev.com/web/articles.php?id=6

Posted: Wed Mar 08, 2006 5:26 pm
by feyd
This was just asked.

viewtopic.php?t=45177

Posted: Wed Mar 08, 2006 5:34 pm
by JellyFish
Okay works perfect, thanks wtf. :) And thanks feyd for your reply, I guess I should allways check if there's allready a post on a topic I'm going to post. :)