On Thu, Jun 21, 2012 at 1:47 AM, nn6eumtr <nn6eu...@gmail.com> wrote:
> > If I have a table: > > create table tmp ( > x integer, > y integer > ) > > And a an index with compound key: > > create unique index idx on tmp (x, y); > > And I did a query: > > select * from tmp where x = 9 > > Would sqlite know how to use the index to find records where x = 9? Or > would it opt for a scan instead? > It will use the index. > > > ______________________________**_________________ > sqlite-users mailing list > sqlite-users@sqlite.org > http://sqlite.org:8080/cgi-**bin/mailman/listinfo/sqlite-**users<http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users> > -- D. Richard Hipp d...@sqlite.org _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users