Re: Pick a row, any row.

From: Date: Fri, 18 May 2001 04:08:07 +0000
Subject: Re: Pick a row, any row.
References: 1 2  Groups: php.db 
Request: Send a blank email to php-db+get-9419@lists.php.net to get a copy of this message
the syntax "order by rand()" is new in version 3.23 -- Regards, Gary "SuperID" Huntress ======================================================= FreeSQL.org offering free database hosting to developers Visit http://www.freesql.org ""Johannes Janson"" <johannes.janson@gmx.de> wrote in message news:9e11f0$eog$1@toye.p.sourceforge.net... > Hi, > > > How can I pick a random row? > > SELECT * FROM table ORDER BY RAND() LIMIT 0, 1; > I'm not really sure but it worked with order by rand. Check > the manual on that if it doesn't work > > hope it helps > Johannes > > > > -- > PHP Database Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-db-unsubscribe@lists.php.net > For additional commands, e-mail: php-db-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net >

« previous php.db (#9419) next »