Thanks for sticking with it and solving the puzzle for me (and all of us), 
Thomas! That’s a lot of bits to combine, and so many of us use H2 for testing, 
where this would show up.

Dave

> On Jun 18, 2015, at 1:51 AM, Thomas Mueller <[email protected]> 
> wrote:
> 
> Hi,
> 
> Thanks a lot! I could simplify the test to just this:
> 
>   drop table test;
>   create table test(id int, name varchar);
>   insert into test values (2, 'a'), (1, 'a');
>   create index on test(name);
>   explain select id from test where name = 'a' order by id;
> 
> The root cause seems to be a recent change in version 1.4.186: "Make the 
> planner use indexes for sorting when doing a GROUP BY where all of the GROUP 
> BY columns are not mentioned in the select. Patch by Frederico (zepfred)."
> 
> I think I will just undo that change. If somebody is interested to fix the 
> problem, please submit a pull request. This time I will be more cautious 
> about accepting changes that I don't understand. For example the method 
> "isDisjunctive" needs a much better explanation or name (even thought the bug 
> is probably not there).
> 
> Regards,
> Thomas
> 

-- 
You received this message because you are subscribed to the Google Groups "H2 
Database" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/h2-database.
For more options, visit https://groups.google.com/d/optout.

Reply via email to