Thank you for the answer as well as the merge-join complexity remark. What about the union-all with ordered input and an order-by on the whole query? Does SQLite use a "merge" algorithm for that case?

Kind regards,

l.

On 26/06/14 21:45, Richard Hipp wrote:



On Thu, Jun 26, 2014 at 11:41 AM, Eleytherios Stamatogiannakis
<est...@gmail.com <mailto:est...@gmail.com>> wrote:

    Hi,

    I've seen that SQLite supports the "SorterOpen" Op, to do merge
    sorting. So based on that, does SQLite support merge joins when both
    inputs of the join are sorted?


No, not at this time.  Note that a merge-join is more complicated than
it appears at first glance for the common case where the join key is not
unique in one or the other of the two tables being joined.


--
D. Richard Hipp
d...@sqlite.org <mailto:d...@sqlite.org>

_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to