Guilherme <gbmpere...@gmail.com> wrote: > I believed that databases in general evaluate their queries, following a > execution plan... > e.g. first do a table scan and apply a filter from the where clause.. than > use the results to execute a join with other table.. than use the results to > excute with another join.. > > but now, from what I've seen, sqlite just does a nested loop, and returns > (if available) a row in each loop...
I don't understand the difference. How does "does a nested loop" differ from "follows an execution plan"? SQLite follows an execution plan that, often, involves a loop. How exactly do you think other databases "do a table scan", if not with a loop? In SQLite, execute any SQL statement with the keyword EXPLAIN prepended, e.g. "explain select * from SomeTable;". The output is SQLite's execution plan for that query. See also: http://sqlite.org/vdbe.html http://sqlite.org/opcode.html -- Igor Tandetnik _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users