Re: Returning Rows in Random Order

From: Howard J. Rogers <howardjr_at_www.com>
Date: Thu, 8 Mar 2001 07:26:38 +1100
Message-ID: <3aa69955_at_news.iprimus.com.au>


[Quoted] But an order by rowid should do the trick.

Not quite entirely random and fresh each time you run the select, but given [Quoted] that table data is in random order, the output with a 'group by rowid' will [Quoted] then be in the same random order.

Regards
HJR "jack straw" <sacque_at_yahoo.com> wrote in message news:985g4e$nub$1_at_linux1.netconx.de...
> well, there is an index unfortunately :(
>
> "Happl Oberlin" <happl_at_mail.com> wrote in message
> news:happl-F778E4.14173507032001_at_news.fu-berlin.de...
> > In article <985a58$kl9$1_at_linux1.netconx.de>, "jack straw"
 <sacque_at_yahoo.com> wrote:
> >
> > >Is there a way to return rows from a SELECT statement in a random
 order?
> > >I have found ways to do it in SQL server, but not in Oracle.
> >
> > If there is no ORDER BY or GROUP BY in the query and
> > ORACLE does not use an index to retrieve the data,
> > the rows are returned in random order.
> >
> > Greetings from Switzerland -- Gruesse aus der Schweiz
> > Happl
>
>
Received on Wed Mar 07 2001 - 21:26:38 CET

Original text of this message