It looks like an issue in H2 database engine, but it was fixed in newest versions.
In Ignite-1.7.0 (which is on the vote right now) we upgraded H2, so it must be ok. Sergi 2016-08-04 11:19 GMT+03:00 Zhengqingzheng <[email protected]>: > Hi there, > > When we using ignite sql query, we find that IN clause cannot use indexing > when adding extra ‘and xxx’ clause. > > Here are the descriptions : > > If using ‘IN’ clause like this, and set col1 to be indexed. It works fine. > > select * from table1 where col1 in (?,?,?); > > However, if you add more ‘and’ clause like this: > > select * from table1 where col1 in (?,?,?) and col2=?; > > it will scan the table without going into indexing search. > > > > Any suggestions? > > > > Best regards, > > Kevin > > >
