Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: Perl and MySQL - getting a random record

by tstock (Curate)
on Feb 06, 2003 at 06:51 UTC ( #233068=note: print w/ replies, xml ) Need Help??


in reply to Perl and MySQL - getting a random record

I agree this has nothing to do with perl... and Cody's post got me thinking. try

SELECT *, rand() as rand FROM Banner_Rotator ORDER BY rand LIMIT 1
tstock


Comment on Re: Perl and MySQL - getting a random record
Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://233068]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others surveying the Monastery: (20)
As of 2015-07-07 22:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (93 votes), past polls