I know that the answer is "no", but in the below example, group by clause is meaningless, because (a,b) is primary key and there is no two rows with equal (a, b) that to be grouped.
Please, comment my example from the first email in the thread. Is it possible to make this query to group by and order by simultaneously without using temp b-tree? On Sun, 16 Sep 2018 10:59:31 -0400 Richard Hipp <d...@sqlite.org> wrote: > On 9/16/18, John Found <johnfo...@asm32.info> wrote: > > > > Is it means that in every query that uses GROUP BY and ORDER BY > > simultaneously, one of the operations will always be provided by using > > temporary b-tree? > > > > no. > > CREATE TABLE t1(a,b,c, PRIMARY KEY(a,b)) WITHOUT ROWID; > explain query plan > SELECT a, b, sum(c) FROM t1 GROUP BY a, b ORDER BY a, b; > > -- > D. Richard Hipp > d...@sqlite.org > _______________________________________________ > sqlite-users mailing list > sqlite-users@mailinglists.sqlite.org > http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users -- John Found <johnfo...@asm32.info> _______________________________________________ sqlite-users mailing list sqlite-users@mailinglists.sqlite.org http://mailinglists.sqlite.org/cgi-bin/mailman/listinfo/sqlite-users