/ Published in: SQL
URL: http://www.phpfreaks.com/forums/index.php?topic=125759.0
Using subqueries...
Expand |
Embed | Plain Text
SELECT name FROM tablename WHERE id >= FLOOR( RAND( ) * ( SELECT MAX( id ) FROM tablename ) ) ORDER BY id ASC LIMIT 1
You need to login to post a comment.
