Hi, How many distinct values for "type" are there?
H2 should use the right index, if the statistics are updated. Maybe you need to do that manually by running "analyze", but it should automatically be done from time to time. Not sure what the problem is here. Regards, Thomas On Thursday, June 4, 2015, Rinse Lemstra <[email protected] <javascript:_e(%7B%7D,'cvml','[email protected]');>> wrote: > > > Op donderdag 4 juni 2015 10:59:28 UTC+2 schreef Stig Christensen: >> >> Just add two indexes >> > > I tried, then H2 prefers using the single index and is slow again. > > > -- > 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. > -- 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.
