On 17 Feb 2014, at 7:59am, Max Vlasov <max.vla...@gmail.com> wrote: > So the nanosec example modified > > Select v-v from > ( > Select nanosec() as v from TestTable > ) > > ...shows non-zero values for the current (3.8.3) and for older (3.6.10) > version.
Erm ... that worries me a little. I don't know how SQLite handles sub-selects internally. But the conventional way of doing them is a JOIN to a VIEW. Which means that v-v should always equal zero. By the way, when figuring out how to optimize this still it's worth noting that a parameterless function is rare in SQL. It's rarely worth optimizing unnamed expressions because you rarely get the same unnamed expression (including parameters) used twice. Simon. _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users