Re: Strategy needed for picking random rows
Hi Øystein,
the outer query selects many fields from the 'members' table (and might even include some more LEFT JOINs on one or two other tables), that's why I was saying "m.bulky_field1, ...". The inner query uses only index fields, which performs better ("covering index strategy").
The idea with LIMIT is not really satisfying, because, AFAIK, the optimizier still scans every row up to the given limit and then discards the unneeded rows. Also, I'd need to precompute the maximum limit - no option.
Subject
Views
Written By
Posted
3284
September 07, 2011 11:27AM
1370
September 08, 2011 01:08AM
Re: Strategy needed for picking random rows
1145
September 08, 2011 01:17AM
1116
September 08, 2011 07:51AM
1182
September 08, 2011 08:05AM
1145
September 09, 2011 08:51AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.