View Single Post
  #6 (permalink)  
Old 10-26-2006, 11:29 AM
dirkfirst dirkfirst is offline
Programming Professional
 
Join Date: May 2006
Posts: 338
Credits: 0
Rep Power: 12
dirkfirst is on a distinguished road
Default

Quote:
Originally Posted by Jordan View Post
Just use the rand() function of MySQL.

Code:
SELECT * FROM tbl ORDER BY RAND() LIMIT 1;

Thanks, works perfect.
__________________
DirkFirst
Reply With Quote