MySQL Forums
Forum List  »  Optimizer & Parser

Re: Queries using WHERE IN and ORDER BY LIMIT
Posted by: Nikita Dubrovsky
Date: February 14, 2011 07:06PM

Thanks Rick!

The real query is retrieving the full rows, but I was getting the timings by retrieving just the ids to eliminate one of the variables. On MySQL this doesn't seem to have any impact, but on Oracle if the table has a CLOB column, splitting the query into 2 queries makes a big difference (get the ids first, then get the full rows for just those ids).

It would be cool if the MySQL optimizer could automatically execute these kinds of queries as a union behind the scenes :)

Nikita

Options: ReplyQuote


Subject
Views
Written By
Posted
Re: Queries using WHERE IN and ORDER BY LIMIT
1581
February 14, 2011 07:06PM


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.