> >>>>> "Ryan" == Ryan Mahoney <ryan@paymentalliance.net> writes:
>
> Ryan> Is there an easy way to randomize the order that records get returned in?
> Ryan> Don't imagine there is - but thought I'd ask ;)
>
> order by random()
>
> I even threw it into my latest Linux Magazine column, expounding the
> virtues of the official Database of RedHat.
I still haven't figured out how that function call does this trick.
My guess is that because we can order by a function, it is calling
random() for every row and just sorting on that. In normal usage, the
functionm would reference database columns.
--
Bruce Momjian | http://candle.pha.pa.us
pgman@candle.pha.pa.us | (610) 853-3000
+ If your life is a hard drive, | 830 Blythe Avenue
+ Christ can be your backup. | Drexel Hill, Pennsylvania 19026